切换npm到淘宝镜像
查看 npm 镜像地址
npm get registry
切换为淘宝镜像地址
npm config set registry http://registry.npm.taobao.org/
切换回原始镜像地址
npm config set registry https://registry.npmjs.org/
查看 npm 镜像地址
npm get registry
切换为淘宝镜像地址
npm config set registry http://registry.npm.taobao.org/
切换回原始镜像地址
npm config set registry https://registry.npmjs.org/
从node.js 官网下载node安装包并执行安装.
npm已经包含在node内,安装完成后,通过查看版本检测安装是否成功,提示输出版本号即为成功
node -v
npm -v
创建包的目录,并完成npm初始化
mkdir npm-test
cd npm-test
npm init
这时候
山已不是山
海也不是海
迷雾中行走
他们从黑暗中生还
我睁开眼看看
这里笑贫不笑娼
一个GitHub官方的为Visual Studio项目量身定做的gitignore文件,直接在项目根目录下提交这个文件即可。
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
# User-specific files
*.suo
*.user
*.userosscache
*.sln.docstates
# User-specific files (MonoDevelop/Xamarin Studio)
*.userprefs
# Build results
[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
x86/
bld/
[Bb]in/
[Oo]bj/
[Ll]og/
# Visual Studio 2015 cache/options directory
.vs/
# Uncomment if you have tasks that create the
在 Vue 的开发过程中,有时候会遇到根据不同人的权限加载不同的路由问题,经过一番测试,找到了一个解决方案,举例如:
[
{
"title": "Dashboard",
"path": "/main/",
"src": "dashboard",
"summary": "statistics, charts, recent events and reports",
"children": []
},
{
"title": "Menu Example",
"heading": true
},
{
"title": "Multi Level Menu",
"summary": "",
"children": [
{
"title": "Item 1",
"summary": "",
"children": [
{
"title": "Item 11",
"summary": "",
"path": "/main/1",
"children": []
},
{
"title": "Item 12",
"summary": "",
"path": "/main/1",
"children": []
},
{
"title": "Item 13",
"summary": "",
"path": "/main/1",
"children": []
}
]
},
{
"title": "Item 2",
"summary": "",
"path": "/main/1",
"children": []
},
{
"title": "Item 3",
"summary": "",
"path": "/main/1",
"children": []
}
]
}