mirror of
https://github.com/gpxstudio/gpx.studio.git
synced 2026-11-01 12:17:18 +00:00
lint fixes
This commit is contained in:
1 parent
f5a2db0565
commit
6956c19410
45 files changed
+243
-244
No files matched your search
@@ -15,9 +15,9 @@ export async function load({ params }) {
|
||||
const { language } = params;
|
||||
|
||||
const guideTitles: Record<string, string> = {};
|
||||
for (let guide of Object.keys(guides)) {
|
||||
for (const guide of Object.keys(guides)) {
|
||||
guideTitles[guide] = (await getModule(language, guide)).metadata.title;
|
||||
for (let subguide of guides[guide]) {
|
||||
for (const subguide of guides[guide]) {
|
||||
guideTitles[`${guide}/${subguide}`] = (
|
||||
await getModule(language, `${guide}/${subguide}`)
|
||||
).metadata.title;
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
if (page.params.language) {
|
||||
let lang = page.params.language.replace('/', '');
|
||||
if (i18n.lang !== lang) {
|
||||
if (languages.hasOwnProperty(lang)) {
|
||||
if (Object.hasOwn(languages, lang)) {
|
||||
i18n.lang = lang;
|
||||
} else if (browser) {
|
||||
goto(`${base}/404`);
|
||||
|
||||
@@ -145,7 +145,7 @@
|
||||
{elevationFill}
|
||||
/>
|
||||
</div>
|
||||
<GPXStatistics {statistics} {slicedStatistics} orientation={'horizontal'} />
|
||||
<GPXStatistics {statistics} {slicedStatistics} orientation="horizontal" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="grid md:grid-rows-subgrid md:row-start-3 md:row-end-5 gap-4">
|
||||
|
||||
@@ -3,14 +3,14 @@ import { guides } from '$lib/components/docs/docs';
|
||||
import type { EntryGenerator } from './$types';
|
||||
|
||||
export const entries: EntryGenerator = () => {
|
||||
let entries = [];
|
||||
for (let lang of Object.keys(languages)) {
|
||||
for (let guide of Object.keys(guides)) {
|
||||
const entries = [];
|
||||
for (const lang of Object.keys(languages)) {
|
||||
for (const guide of Object.keys(guides)) {
|
||||
entries.push({
|
||||
language: lang == 'en' ? '' : lang,
|
||||
guide,
|
||||
});
|
||||
for (let subguide of guides[guide]) {
|
||||
for (const subguide of guides[guide]) {
|
||||
entries.push({
|
||||
language: lang == 'en' ? '' : lang,
|
||||
guide: `${guide}/${subguide}`,
|
||||
|
||||
Reference in new issue
Block a user