Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

调试配置指引 #1

Open
haiweilian opened this issue Jan 12, 2024 · 0 comments
Open

调试配置指引 #1

haiweilian opened this issue Jan 12, 2024 · 0 comments

Comments

@haiweilian
Copy link
Owner

haiweilian commented Jan 12, 2024

编写时使用 yarn v1.x 、node v16.x

Vue 调试

  • 构建开发版本
cd vue-next-3.2.0
yarn install
yarn build
  • 构建完成后会有以下文件

image

  • 在 Chrome 中调试

由于需要写很多的小测试,也避免经过工具转换更复杂所以就直接写在 html 了。可以通过 LiveServer 启动一个静态服务在浏览器调试。

image

image

  • 在 VsCode 中调试

上面的服务不要关,启动 vscode 中的服务。会启动一个新的浏览器窗口,访问要调试的页面。

image

image

image

Pinia / Vuex / VueRouter 调试

这三个操作步骤一致,以 Pinia 举例演示。

  • 构建开发版本
cd pinia-2.0.0
yarn install
yarn build
  • 构建完成后会有以下文件

image

  • 在 Chrome 中调试
// 启动调试项目
cd pinia-examples
yarn install
yarn dev

image

  • 在 VsCode 中调试

上面的服务不要关,启动 vscode 中的服务。会启动一个新的浏览器窗口,访问要调试的页面。

image

image

@haiweilian haiweilian pinned this issue Jan 12, 2024
@haiweilian haiweilian changed the title 调试配置 调试配置指引 Jan 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant