Skip to content

Commit

Permalink
chore: pnpm fmt (#6108)
Browse files Browse the repository at this point in the history
  • Loading branch information
wmertens authored Apr 9, 2024
1 parent 4c31871 commit 86ef804
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,22 @@ import { component$ } from "@builder.io/qwik";
import { Link, useLocation } from "@builder.io/qwik-city";

export default component$((props) => {
const { url: { pathname } } = useLocation();
const {
url: { pathname },
} = useLocation();

const isProjects = pathname.includes('projects')
const hrefPath = isProjects ? 'projekte' : 'projects'
const isProjects = pathname.includes("projects");
const hrefPath = isProjects ? "projekte" : "projects";

return (
<div>
<h1>Issue 5665</h1>
<p>Translated routes from rewriteRoutes get ignored for [...catchall] route in same folder</p>
<p>
Translated routes from rewriteRoutes get ignored for [...catchall] route
in same folder
</p>
<Link href={`/qwikcity-test/issue5665/${hrefPath}`}>
Go to {isProjects ? 'projekte' : 'projects'}
Go to {isProjects ? "projekte" : "projects"}
</Link>
</div>
);
Expand Down
18 changes: 10 additions & 8 deletions starters/dev-server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -165,15 +165,17 @@ export {
const qwikCityVite: typeof import("@builder.io/qwik-city/vite") =
await import(file(qwikCityDistVite));

plugins.push(qwikCityVite.qwikCity({
rewriteRoutes: [
{
paths: {
'projects': 'projekte'
plugins.push(
qwikCityVite.qwikCity({
rewriteRoutes: [
{
paths: {
projects: "projekte",
},
},
},
]
}));
],
}),
);
}

const getInlineConf = (extra?: InlineConfig): InlineConfig => ({
Expand Down

0 comments on commit 86ef804

Please sign in to comment.