Skip to content

Commit

Permalink
chore(lint): fix lint issues (withastro#3743)
Browse files Browse the repository at this point in the history
Co-authored-by: Nate Moore <nate@astro.build>
  • Loading branch information
natemoo-re and natemoo-re authored Jun 28, 2022
1 parent 768c8ed commit 53bf0be
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/create-astro/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import { TEMPLATES } from './templates.js';
function wait(ms: number) {
return new Promise((resolve) => setTimeout(resolve, ms));
}
function logAndWait(message: string, ms: number = 100) {
function logAndWait(message: string, ms = 100) {
console.log(message);
return wait(ms);
}
Expand Down
4 changes: 2 additions & 2 deletions packages/integrations/prefetch/src/client.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/// <reference path="../@types/network-information.d.ts" />
import "../@types/network-information.d.ts";
import throttles from 'throttles';
import requestIdleCallback from './requestIdleCallback.js';

Expand Down Expand Up @@ -53,7 +53,7 @@ async function preloadHref(link: HTMLAnchorElement) {
const html = parser.parseFromString(contents, 'text/html');
const styles = Array.from(html.querySelectorAll<HTMLLinkElement>('link[rel="stylesheet"]'));

await Promise.all(styles.map(({ href }) => fetch(href)));
await Promise.all(styles.map((el) => fetch(el.href)));
} catch {}
}

Expand Down

0 comments on commit 53bf0be

Please sign in to comment.