Code Monkey home page Code Monkey logo

vit's People

Contributors

scrum avatar yunsii avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

vit's Issues

想请教动态路由怎麽设定

前辈们好,目前在实作使用到像这样的动态路由

{ path: '/process-pending/:id/detail', icon: 'FileSearch', name: '查询明细', component: './pages/ProcessPending/Detail/index.jsx', hideInMenu: true },

使用开发模式 vite 可正常执行,但执行 vite build 打包却会出现路径不合法的错误

error during build: Error: Illegal characters in path. at pathArg (C:\Users\BLKsherry\Desktop\Project\frontend\node_modules\mkdirp\lib\path-arg.js:20:27) at Function.mkdirpSync [as sync] (C:\Users\BLKsherry\Desktop\Project\frontend\node_modules\mkdirp\index.js:18:10) at Service.writeFile (C:\Users\BLKsherry\Desktop\Project\frontend\node_modules\@vitjs\core\dist\Service\index.js:49:26) at C:\Users\Sherry.Bing\Desktop\Project\Bothwell\bothwell\frontend\node_modules\@vitjs\vit\dist\preset\exportStatic.js:23:17 at Array.map (<anonymous>) at exportStatic (C:\Users\BLKsherry\Desktop\Project\frontend\node_modules\@vitjs\vit\dist\preset\exportStatic.js:18:12) at Object.closeBundle (C:\Users\BLKsherry\Desktop\Project\frontend\node_modules\@vitjs\vit\dist\vitApp.js:37:39) at file:///C:/Users/BLKsherry/Desktop/Project/frontend/node_modules/rollup/dist/es/shared/rollup.js:22748:40 at processTicksAndRejections (node:internal/process/task_queues:96:5) at async Promise.all (index 0) at async PluginDriver.hookParallel (file:///C:/Users/BLKsherry/Desktop/Project/frontend/node_modules/rollup/dist/es/shared/rollup.js:22676:9) at async Object.close (file:///C:/Users/BLKsherry/Desktop/Project/frontend/node_modules/rollup/dist/es/shared/rollup.js:23750:13) at async Promise.all (index 0) at async build (file:///C:/Users/BLKsherry/Desktop/Project/frontend/node_modules/vite/dist/node/chunks/dep-c842e491.js:46421:13) at async CAC.<anonymous> (file:///C:/Users/BLKsherry/Desktop/Project/frontend/node_modules/vite/dist/node/cli.js:756:9)

想请问应该怎麽设置呢?谢谢!

is vit support vite's `resolve.alias` ?

the code below seems not working :

// vite.config.ts
export default defineConfig({
  vitApp({
    // vit configs ...
  }),
  // some other vite configs ...
  resolve: {
    alias: {
      "~/": path.resolve(__dirname, "./"),
      "~": path.resolve(__dirname, "./node_modules/"),
      "@/": path.resolve(__dirname, "/src/"),
      "~@/": path.resolve(__dirname, "/src/"),
      "lodash": 'lodash-es',
      "~antd": path.resolve(__dirname, "./node_modules/antd/"),
    },
  },
})

Having an issue with a basic react app

Hello, I tried to reproduce the example at yunsii/vite-react

I end up with these errors and a blank page 😢

CleanShot 2022-07-08 at 22 55 28

My _app.tsx, vite.config.ts and routes.ts are the exact same as shown in yunsii/vite-react

请教下你咋解决这个错误得 error TS7016: Could not find a declaration file for module 'react-color'.

yarn run v1.22.17
$ tsc && vite build
node_modules/@ant-design/pro-form/lib/components/ColorPicker/index.d.ts:2:40 - error TS7016: Could not find a declaration file for module 'react-color'. 'C:/Users/pwt/src/vitereacttest/node_modules/react-color/lib/index.js' implicitly has an 'any' type.
Try npm i --save-dev @types/react-color if it exists or add a new declaration (.d.ts) file containing declare module 'react-color';

2 import type { SketchPickerProps } from 'react-color';
~~~~~~~~~~~~~

node_modules/@ant-design/pro-utils/lib/types/index.d.ts:4:40 - error TS7016: Could not find a declaration file for module 'react-color'. 'C:/Users/pwt/src/vitereacttest/node_modules/react-color/lib/index.js' implicitly has an 'any' type.
Try npm i --save-dev @types/react-color if it exists or add a new declaration (.d.ts) file containing declare module 'react-color';

4 import type { SketchPickerProps } from 'react-color';
~~~~~~~~~~~~~

Found 2 errors in 2 files.

Errors Files
1 node_modules/@ant-design/pro-form/lib/components/ColorPicker/index.d.ts:2
1 node_modules/@ant-design/pro-utils/lib/types/index.d.ts:4
error Command failed with exit code 2.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.