diff --git a/.github/actions/update-stars/main.js b/.github/actions/update-stars/main.js index a10690e72..1905fbb02 100644 --- a/.github/actions/update-stars/main.js +++ b/.github/actions/update-stars/main.js @@ -1,8 +1,8 @@ import core from '@actions/core'; import { writeFileSync } from 'node:fs'; -import components from '../src/routes/components/components.json' assert { type: 'json' }; -import templates from '../src/routes/templates/templates.json' assert { type: 'json' }; -import tools from '../src/routes/tools/tools.json' assert { type: 'json' }; +import components from '../../../src/routes/components/components.json' assert { type: 'json' }; +import templates from '../../../src/routes/templates/templates.json' assert { type: 'json' }; +import tools from '../../../src/routes/tools/tools.json' assert { type: 'json' }; import { fetch } from 'undici'; const ghGraphQlUrl = 'https://api.github.com/graphql'; diff --git a/.gitpod.yml b/.gitpod.yml deleted file mode 100644 index 167a8b2fe..000000000 --- a/.gitpod.yml +++ /dev/null @@ -1,42 +0,0 @@ -ports: - - port: 3000 - onOpen: open-preview - - port: 10000 - onOpen: ignore - -# List the start up tasks. You can start them in parallel in multiple terminals. See https://www.gitpod.io/docs/config-start-tasks/ -tasks: - - init: curl -f https://get.pnpm.io/v6.js | node - add --global pnpm && pnpm install - command: | - echo "Applying a temporary workaround until https://github.com/vitejs/vite/pull/1992 is fixed" - ( - cd ./node_modules/vite/dist/node/chunks/ && - sed -i 's/JSON.stringify(port)/JSON.stringify(443)/g' * && - export WSS_HOST=`gp url 24678 | sed 's#https://##g'` && - sed -i "s#JSON.stringify(host)#JSON.stringify(\"$WSS_HOST\")#g" * - ) - pnpm dev - -github: - prebuilds: - # enable for the master/default branch (defaults to true) - master: true - # enable for all branches in this repo (defaults to false) - branches: true - # enable for pull requests coming from this repo (defaults to true) - pullRequests: true - # enable for pull requests coming from forks (defaults to false) - pullRequestsFromForks: true - # add a check to pull requests (defaults to true) - addCheck: true - # add a "Review in Gitpod" button as a comment to pull requests (defaults to false) - addComment: false - # add a "Review in Gitpod" button to the pull request's description (defaults to false) - addBadge: true - # add a label once the prebuild is ready to pull requests (defaults to false) - addLabel: false - -vscode: - extensions: - - svelte.svelte-vscode - - esbenp.prettier-vscode diff --git a/package.json b/package.json index 3a9c4c566..21dcb15b7 100644 --- a/package.json +++ b/package.json @@ -11,8 +11,8 @@ "sync": "svelte-kit sync", "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json", "test": "vitest", - "lint": "prettier --check ./**/*.{js,ts,css,md,svelte,html,json} && eslint . && node scripts/validateData.js", - "format": "prettier --write ./**/*.{js,ts,css,md,svelte,html,json}", + "lint": "prettier --check ./**/*.{js,cjs,ts,css,md,svx,svelte,html,json} && eslint . && node scripts/validateData.js", + "format": "prettier --write ./**/*.{js,cjs,ts,css,md,svx,svelte,html,json}", "prepare": "husky install" }, "devDependencies": { @@ -23,6 +23,7 @@ "@sveltejs/kit": "^2.0.0", "@sveltejs/vite-plugin-svelte": "^3.0.1", "@types/itemsjs": "^2.1.6", + "@types/eslint": "^8.44.9", "@types/node": "^20.10.4", "@typescript-eslint/eslint-plugin": "^6.14.0", "@typescript-eslint/parser": "^6.14.0", @@ -51,6 +52,6 @@ "zod": "^3.22.4" }, "lint-staged": { - "*.{js,ts,css,md,svx,svelte,html,json}": "prettier --write" + "*.{js,cjs,ts,css,md,svx,svelte,html,json}": "prettier --write" } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index a5047b068..17a7d72e8 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -23,6 +23,9 @@ devDependencies: '@sveltejs/vite-plugin-svelte': specifier: ^3.0.1 version: 3.0.1(svelte@4.2.8)(vite@5.0.10) + '@types/eslint': + specifier: ^8.44.9 + version: 8.44.9 '@types/itemsjs': specifier: ^2.1.6 version: 2.1.6 @@ -674,6 +677,13 @@ packages: resolution: {integrity: sha512-4Kh9a6B2bQciAhf7FSuMRRkUWecJgJu9nPnx3yzpsfXX/c50REIqpHY4C82bXP90qrLtXtkDxTZosYO3UpOwlA==} dev: true + /@types/eslint@8.44.9: + resolution: {integrity: sha512-6yBxcvwnnYoYT1Uk2d+jvIfsuP4mb2EdIxFnrPABj5a/838qe5bGkNLFOiipX4ULQ7XVQvTxOh7jO+BTAiqsEw==} + dependencies: + '@types/estree': 1.0.1 + '@types/json-schema': 7.0.12 + dev: true + /@types/estree@1.0.1: resolution: {integrity: sha512-LG4opVs2ANWZ1TJoKc937iMmNstM/d0ae1vNbnBvBhqCSezgVUOzcLCqbI5elV8Vy6WKwKjaqR+zO9VKirBBCA==} dev: true diff --git a/src/routes/recipes/svelte-language-fundamentals/reactivity/+page.svx b/src/routes/recipes/svelte-language-fundamentals/reactivity/+page.svx index 95df4030d..293e6566f 100644 --- a/src/routes/recipes/svelte-language-fundamentals/reactivity/+page.svx +++ b/src/routes/recipes/svelte-language-fundamentals/reactivity/+page.svx @@ -25,6 +25,7 @@ The following works as expected and update the dom: +
{num}
``` @@ -91,6 +92,7 @@ This is the sort of problem you may run into when dealing with objects. Since ob +{obj.num}
``` @@ -112,6 +114,7 @@ Another situation that can sometimes cause unexpected results is when you reassi +{num}
``` diff --git a/svelte.config.js b/svelte.config.js index 6e1d3f7e2..ead1b487c 100644 --- a/svelte.config.js +++ b/svelte.config.js @@ -44,6 +44,7 @@ const config = { config.include = [ ...config.include, '../scripts/**/*.js', + '../.eslintrc.cjs', '../prettier.config.js', '../svelte.config.js' ];