Comments (6)
@leishihong 你好,想问一下可以贴一下关于vconsole的vite配置,vite版本,插件版本和vconsole版本嘛
from vite-plugin-vconsole.
vite.config.ts 配置
viteVConsole({
entry: pathResolve('src/main.ts').replace(/\/g, '/'),
localEnabled: command === 'serve',
enabled: command !== 'serve' || mode === 'test',
config: {
maxLogNumber: 1000,
theme: "dark",
},
}),
"vconsole": "^3.12.0",
"vite": "^2.7.2",
"vite-plugin-vconsole": "^1.1.1",
没有在main.ts 中引入vconsole 引入以后就报错了
from vite-plugin-vconsole.
from vite-plugin-vconsole.
@leishihong
方便贴一下main.ts中关于vconsole处理的代码嘛?
另:在main.ts可以不需要引入vconsole,配置里配置开启就可以看到vconsole了。entry配置的.replace(//g, '/')这行可以不用处理了,V1.1.1+处理过这个window问题。
from vite-plugin-vconsole.
from vite-plugin-vconsole.
@leishihong 有最小可复现的代码嘛?方便在CodeSandbox/CodePen/jsFiddle等平台配一个看看嘛?
联系邮箱[email protected]
from vite-plugin-vconsole.
Related Issues (15)
- vite-plugin-vconsole 该插件是不是有问题? HOT 4
- 参数设计的让人很费解 HOT 2
- vite 3.0能用吗? HOT 4
- 如何判断页面userAgent来选择是否加载vconsole HOT 2
- 控制台的日志指向的是vconsole.min.js,可以通过配置直接查看到源文件或者打包压缩过的代码吗? HOT 1
- 动态显示vconsole HOT 1
- 如何自定义vconsole插件 HOT 2
- 为什么只允许 pnpm ? HOT 3
- 老哥,你起码应该在 README 中介绍一下这个项目的作用啊 HOT 1
- customHide参数的判断时机可以适当提前 HOT 1
- 求助帖:请问如何动态修改主题? HOT 5
- build开启sourcemap,会有很多警告 HOT 2
- JSON.stringify 转换 config 转不了函数
- error: [plugin externalize-deps] Failed HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vite-plugin-vconsole.