首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >只有在保存svelte.config.js之后才会应用更改。(似乎通过HMR建设失败了。)

只有在保存svelte.config.js之后才会应用更改。(似乎通过HMR建设失败了。)
EN

Stack Overflow用户
提问于 2022-11-09 10:11:18
回答 1查看 110关注 0票数 0

我的问题

  • 即使我在文件中做了一个更改,它也没有反映在结果上。
  • 在我保存了一处零钱后,代码就在闪烁。
  • 但是,只有在我保存了svelte.config.js而不更改svelte.config.js中的任何内容之后,它才会反映在结果上。

在我做了改变后,代码在闪烁。

我挣扎了三天。看来HMR不起作用了。更确切地说,我想建筑是失败的,当它是通过HMR完成。

在第一个开发项目开始时,它可以工作。但是,当我在文件中进行更改并保存它时,它不会应用更改。在保存我的更改而没有反映浏览器的结果后,代码一直在闪烁。

但奇怪的是,它只在保存svelte.config.js文件之后才会反映变化。在我保存svelte.config.js之后,开发服务器就会重新启动,代码的闪烁效果就会停止并反映更改。我首先想,“也许只有在服务器重新启动之后,它才能工作吗..?”但事实并非如此,当我浏览vite.config.js时,变化并没有得到反映。同样的闪烁效果。

现在,每次在任何文件中进行更改时,我都必须保存svelte.config.js文件,而不知道原因。(所以每次做painful......and都要花几秒钟时间)

我录下了我的屏幕

https://www.loom.com/share/71dab382a20547919e07bf410d49fc9d

我的package.json

代码语言:javascript
运行
复制
{
  "name": "sveltekit-typescript-showcase",
  "version": "1.0.0",
  "scripts": {
    "dev": "vite dev",
    "build": "vite build",
    "build:types": "openapi-typescript https://vskodzianevmhpqzmjqd.supabase.co/rest/v1/?apikey=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InZza29kemlhbmV2bWhwcXptanFkIiwicm9sZSI6ImFub24iLCJpYXQiOjE2NTI0Mzg0MTAsImV4cCI6MTk2ODAxNDQxMH0.pqf9e6G8pcMxCdVVIipD-RXJrYV-9RJK_qWruTkjGAg --output src/types/supabase.ts",
    "gen-type-dev": "supabase gen types typescript --db-url postgres://postgres:HappyHyein66!@db.jgxpeedixksinkdlpfwp.supabase.co:6543/postgres",
    "package": "vite package",
    "preview": "vite preview"
  },
  "devDependencies": {
    "@supabase/supabase-js": "^1.35.3",
    "@types/lodash": "^4.14.186",
    "carbon-components-svelte": "^0.65.0",
    "openapi-typescript": "5.4.0",
    "prettier": "^2.6.2",
    "sass": "^1.52.2",
    "svelte": "^3.46.6",
    "svelte-check": "^2.4.6",
    "svelte-preprocess": "^4.10.5",
    "tslib": "^2.3.1",
    "typescript": "~4.6.3",
    "vite": "^3.1.7",
    "@sveltejs/kit": "^1.0.0-next.359"
  },
  "type": "module",
  "dependencies": {
    "@supabase/supabase-js": "^1.35.3",
    "@sveltejs/adapter-vercel": "^1.0.0-next.80",
    "@sveltejs/kit": "^1.0.0-next.359",
    "base64-arraybuffer": "^1.0.2",
    "carbon-icons-svelte": "^11.1.0",
    "svelte": "^3.46.6",
    "encoding": "^0.1.13",
    "lodash": "^4.17.21",
    "nvm": "^0.0.4",
    "supabase": "^0.5.0"
  }
}

svelte.config.js

代码语言:javascript
运行
复制
import vercel from '@sveltejs/adapter-vercel';
import { resolve } from 'path';
import preprocess from 'svelte-preprocess';

const config = {
  // Consult https://github.com/sveltejs/svelte-preprocess
  // for more information about preprocessors
  preprocess: preprocess(),
  alias: {
          $lib: resolve('./src/lib'),
          $models: resolve('./src/models'),
        },
  kit: {
    adapter: vercel()
  },
};

export default config;

vite.config.js

代码语言:javascript
运行
复制
import { sveltekit } from '@sveltejs/kit/vite';
import { resolve } from 'path';

const config = {
        plugins: [sveltekit()],
        resolve: {
        alias: {
          $lib: resolve( './src/lib'),
          $models: resolve('./src/models'),
          $types: resolve('./src/types/index.ts')
        },
      },
        server: {
    fs: {
      // Allow serving files from one level up to the project root
      allow: ['..'],
    },
  },
}

export default config;
  1. 我尝试将svelte.config.js选项添加到vite.config.js中。

vite.config.js

代码语言:javascript
运行
复制
import { sveltekit } from '@sveltejs/kit/vite';
import { resolve } from 'path';

const config = {
        plugins: [sveltekit({
            preprocess: preprocess(),
  alias: {
          $lib: resolve('./src/lib'),
          $models: resolve('./src/models'),
        },
  kit: {
    adapter: vercel()
  },
        })],
        resolve: {
        alias: {
          $lib: resolve( './src/lib'),
          $models: resolve('./src/models'),
          $types: resolve('./src/types/index.ts')
        },
      },
        server: {
    fs: {
      // Allow serving files from one level up to the project root
      allow: ['..'],
    },
  },
}

export default config;
  1. 阅读后更新npm (svelte - Vite+SvelteKit构建失败-堆栈溢出)
  2. 删除vite.config.js中的别名选项
  3. 删除node_modules和npm再次安装。有可疑的2条警告。(原始日志附后)
  4. 6:36:53 PM vite更改了检测到的tsconfig文件: C:\Users\Jooyeon\Downloads\modeny-svelte-typescript\tsconfig.json - Clearing缓存,并强制完全重新加载以确保使用更新的配置值编译TypeScript。
  5. npm警告nvm@0.0.4:这不是正确的nvm。访问https://nvm.sh并使用curl命令来安装它。
代码语言:javascript
运行
复制
// Raw
6:26:23 PM [vite] server restarted.

  ➜  Local:   http://127.0.0.1:5173/
  ➜  Network: use --host to expose

The following Vite config options will be overridden by SvelteKit:
  - resolve.alias.$lib
6:26:24 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/src/lib/component/Sidebar.svelte:111:0 Unused CSS selector ".menu-icon.home"
6:26:24 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/src/lib/component/Sidebar.svelte:123:0 Unused CSS selector ".menu-icon.hanger"
6:26:26 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ComposedModal/ComposedModal.svelte:153:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:26 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ComposedModal/ModalBody.svelte:9:0 A11y: noninteractive element cannot have positive tabIndex value
6:26:26 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/CodeSnippet/CodeSnippet.svelte:221:4 A11y: noninteractive element cannot have positive tabIndex value
6:26:27 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/DataTable/DataTableSkeleton.svelte:66:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:27 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/FileUploader/FileUploaderButton.svelte:63:0 A11y: noninteractive element cannot have positive tabIndex value
6:26:27 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/FileUploader/FileUploaderDropContainer.svelte:84:2 A11y: noninteractive element cannot have positive tabIndex value
6:26:27 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ListBox/ListBoxField.svelte:46:0 A11y: noninteractive element cannot have positive tabIndex value
6:26:27 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/Modal/Modal.svelte:242:4 A11y: noninteractive element cannot have positive tabIndex value 
6:26:27 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/NumberInput/NumberInput.svelte:156:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:28 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/Search/Search.svelte:104:4 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:28 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/StructuredList/StructuredListRow.svelte:15:2 A11y: noninteractive element cannot have positive tabIndex value
6:26:28 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/Tile/SelectableTile.svelte:56:0 A11y: noninteractive element cannot have positive tabIndex value
6:26:28 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TextArea/TextArea.svelte:62:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:28 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TimePicker/TimePicker.svelte:55:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:28 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TextInput/TextInput.svelte:103:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:28 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TextInput/PasswordInput.svelte:97:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:28 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/Tooltip/Tooltip.svelte:252:6 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:29 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/UIShell/SideNav.svelte:52:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:29 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/UIShell/HeaderSearch.svelte:64:7 A11y: Elements with the ARIA role "combobox" must have the following attributes defined: "aria-controls", "aria-expanded"
6:26:29 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TreeView/TreeViewNodeList.svelte:135:6 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
data! {}
data! {}
files in the public directory are served at the root path.
Instead of /static/icon/customer.svg, use /icon/customer.svg.
files in the public directory are served at the root path.
Instead of /static/icon/add.svg, use /icon/add.svg.
files in the public directory are served at the root path.
Instead of /static/icon/schedule.svg, use /icon/schedule.svg.
6:26:34 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/src/lib/component/Sidebar.svelte:111:0 Unused CSS selector ".menu-icon.home"
6:26:34 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/src/lib/component/Sidebar.svelte:123:0 Unused CSS selector ".menu-icon.hanger"
data! {}
6:26:37 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ComposedModal/ComposedModal.svelte:153:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:37 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ComposedModal/ModalBody.svelte:9:0 A11y: noninteractive element cannot have positive tabIndex value
6:26:37 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/CodeSnippet/CodeSnippet.svelte:221:4 A11y: noninteractive element cannot have positive tabIndex value
6:26:38 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/DataTable/DataTableSkeleton.svelte:66:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
onents-svelte/src/Tooltip/Tooltip.svelte:252:6 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:43 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TimePicker/TimePicker.svelte:55:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:43 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/UIShell/SideNav.svelte:52:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:26:43 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/UIShell/HeaderSearch.svelte:64:7 A11y: Elements with the ARIA role "combobox" must have the following attributes defined: "aria-controls", "aria-expanded"
6:26:44 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TreeView/TreeViewNodeList.svelte:135:6 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:53 PM [vite] changed tsconfig file detected: C:\Users\Jooyeon\Downloads\modeny-svelte-typescript\tsconfig.json - Clearing cache and forcing full-reload to ensure TypeScript is compiled with updated config values.
6:36:54 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/src/lib/component/Sidebar.svelte:111:0 Unused CSS selector ".menu-icon.home"
6:36:54 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/src/lib/component/Sidebar.svelte:123:0 Unused CSS selector ".menu-icon.hanger"
6:36:56 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ComposedModal/ComposedModal.svelte:153:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:56 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ComposedModal/ModalBody.svelte:9:0 A11y: noninteractive element cannot have positive tabIndex value
6:36:56 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/CodeSnippet/CodeSnippet.svelte:221:4 A11y: noninteractive element cannot have positive tabIndex value
6:36:56 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/DataTable/DataTableSkeleton.svelte:66:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:56 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/FileUploader/FileUploaderButton.svelte:63:0 A11y: noninteractive element cannot have positive tabIndex value
6:36:56 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/FileUploader/FileUploaderDropContainer.svelte:84:2 A11y: noninteractive element cannot have positive tabIndex value
6:36:57 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ListBox/ListBoxField.svelte:46:0 A11y: noninteractive element cannot have positive tabIndex value
6:36:57 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/Modal/Modal.svelte:242:4 A11y: noninteractive element cannot have positive tabIndex value
6:36:57 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/NumberInput/NumberInput.svelte:156:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:57 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/Search/Search.svelte:104:4 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:58 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/StructuredList/StructuredListRow.svelte:15:2 A11y: noninteractive element cannot have positive tabIndex value
6:36:58 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TextInput/TextInput.svelte:103:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:58 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TextInput/PasswordInput.svelte:97:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:58 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/Tile/SelectableTile.svelte:56:0 A11y: noninteractive element cannot have positive tabIndex value
6:36:58 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TimePicker/TimePicker.svelte:55:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:58 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TextArea/TextArea.svelte:62:0 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:58 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/Tooltip/Tooltip.svelte:252:6 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:58 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/UIShell/SideNav.svelte:52:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:36:59 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/UIShell/HeaderSearch.svelte:64:7 A11y: Elements with the ARIA role "combobox" must have the following attributes defined: "aria-controls", "aria-expanded"
6:36:59 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/TreeView/TreeViewNodeList.svelte:135:6 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
data! {}
files in the public directory are served at the root path.
Instead of /static/icon/customer.svg, use /icon/customer.svg.
files in the public directory are served at the root path.
Instead of /static/icon/add.svg, use /icon/add.svg.
files in the public directory are served at the root path.
Instead of /static/icon/schedule.svg, use /icon/schedule.svg.
6:37:01 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/src/lib/component/Sidebar.svelte:111:0 Unused CSS selector ".menu-icon.home"
6:37:01 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/src/lib/component/Sidebar.svelte:123:0 Unused CSS selector ".menu-icon.hanger"
data! {}
6:37:04 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ComposedModal/ComposedModal.svelte:153:2 A11y: visible, non-interactive elements with an on:click event must be accompanied by an on:keydown, on:keyup, or on:keypress event.
6:37:04 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/ComposedModal/ModalBody.svelte:9:0 A11y: noninteractive element cannot have positive tabIndex value
6:37:04 PM [vite-plugin-svelte] C:/Users/Jooyeon/Downloads/modeny-svelte-typescript/node_modules/carbon-components-svelte/src/CodeSnippet/CodeSnippet.svelte:221:4 A11y: noninteractive element cannot have positive tabIndex value
npm WARN deprecated nvm@0.0.4: This is NOT the correct nvm. Visit https://nvm.sh and use the curl command to install it.

added 294 packages, and audited 295 packages in 16s

24 packages are looking for funding
  run `npm fund` for details

4 vulnerabilities (1 moderate, 3 critical)

To address all issues (including breaking changes), run:
  npm audit fix --force

Run `npm audit` for details.
EN

回答 1

Stack Overflow用户

发布于 2022-11-10 10:53:00

查看这里最简单的package.json文件(https://stackblitz.com/edit/sveltejs-kit-template-default-wab2ls?file=package.json&terminal=dev),它位于svelte的头版(https://kit.svelte.dev/),我发现列表上有@type/cookie,而不是我的。

我记得有一次VScode显示了一条关于它的错误消息,所以我把它添加到列表中,然后重新安装,它工作了……

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/74373090

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档