Skip to content

Commit

Permalink
chore: lint
Browse files Browse the repository at this point in the history
  • Loading branch information
florian-lefebvre committed Apr 29, 2024
1 parent fa9ff1b commit 902f742
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion package/src/i18next/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { join, relative } from "node:path";
import { fileURLToPath } from "node:url";
import { watchDirectory, defineUtility } from "astro-integration-kit";
import { defineUtility, watchDirectory } from "astro-integration-kit";
import { normalizePath } from "vite";
import type { Options } from "../options.js";
import { getNamespaces } from "./namespaces.js";
Expand Down
4 changes: 2 additions & 2 deletions package/src/integration.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { readFileSync } from "node:fs";
import {
createResolver,
defineIntegration,
addDts,
addIntegration,
addVirtualImports,
createResolver,
defineIntegration,
} from "astro-integration-kit";
import { handleI18next } from "./i18next/index.js";
import { optionsSchema } from "./options.js";
Expand Down
2 changes: 1 addition & 1 deletion package/src/middleware.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { defineMiddleware } from "astro/middleware";
import { als } from "virtual:astro-i18n/als";
import { i18nextConfig, options, routes } from "virtual:astro-i18n/internal";
import { defineMiddleware } from "astro/middleware";

const extractLocaleFromUrl = (pathname: string) => {
for (const locale of options.locales) {
Expand Down
2 changes: 1 addition & 1 deletion package/src/routing/index.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { defineUtility } from "astro-integration-kit";
import type { Options } from "../options.js";
import { handleRoutesHMR } from "./hmr.js";
import { registerRoutes } from "./register.js";
import { defineUtility } from "astro-integration-kit";

export const ROUTES_DIR = "routes";
const LOGGER_LABEL = "astro-i18n/routing";
Expand Down
2 changes: 1 addition & 1 deletion package/src/routing/register.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ import type {
HookParameters,
InjectedRoute,
} from "astro";
import { defineUtility } from "astro-integration-kit";
import { addPageDir } from "astro-pages";
import { AstroError } from "astro/errors";
import { withLeadingSlash } from "ufo";
import { normalizePath } from "vite";
import type { Options } from "../options.js";
import type { Route } from "../types.js";
import { ROUTES_DIR } from "./index.js";
import { defineUtility } from "astro-integration-kit";

const isPrerendered = (str: string) => {
const match = str.match(/export const prerender = (\w+)/);
Expand Down
2 changes: 1 addition & 1 deletion playground/astro.config.mts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import node from "@astrojs/node";
import react from "@astrojs/react";
import tailwind from "@astrojs/tailwind";
import { defineConfig } from "astro/config";
import { createResolver } from "astro-integration-kit";
import { hmrIntegration } from "astro-integration-kit/dev";
import { defineConfig } from "astro/config";

const { default: i18n } = await import("@astrolicious/i18n");

Expand Down

0 comments on commit 902f742

Please sign in to comment.