Skip to content

Commit

Permalink
feat: add serve in production & 404 template
Browse files Browse the repository at this point in the history
  • Loading branch information
sanyuan0704 committed Sep 13, 2022
1 parent e47598e commit c8bd1fe
Show file tree
Hide file tree
Showing 20 changed files with 531 additions and 177 deletions.
24 changes: 10 additions & 14 deletions docs/.island/config.ts
Expand Up @@ -2,13 +2,13 @@ export default {
lang: 'zh-CN',
themeConfig: {
nav: [
{ text: '架构', link: '/arch/why', activeMatch: '^/$|^/arch/' },
{
text: '构建实现',
link: '/build/1-pre-bundle/esbuild',
activeMatch: '^/build/'
},
{ text: '生态', link: '/eco/plugin-vue', activeMatch: '^/eco/' }
// { text: '架构', link: '/arch/why', activeMatch: '^/$|^/arch/' },
// {
// text: '构建实现',
// link: '/build/1-pre-bundle/esbuild',
// activeMatch: '^/build/'
// },
// { text: '生态', link: '/eco/plugin-vue', activeMatch: '^/eco/' }
],

sidebar: {
Expand All @@ -21,17 +21,13 @@ function getArchSidebar() {
return [
{
text: '前言',
items: [{ text: '为什么写这本书?', link: '/' }]
items: [{ text: '初衷', link: '/' }]
},
{
text: '架构',
items: [
{ text: '小结sdsd', link: '/arch/engine' },
{ text: 'CLI 工具', link: '/arch/cli' },
{ text: '配置解析服务', link: '/arch/config' },
{ text: 'Dev Server 架构', link: '/arch/server-mode' },
{ text: '插件容器机制', link: '/arch/plugin-container' },
{ text: '仓库工作流', link: '/arch/' }
{ text: '快速开始', link: '/arch/engine' },
{ text: 'CLI 工具', link: '/arch/cli' }
]
}
];
Expand Down
41 changes: 32 additions & 9 deletions package.json
Expand Up @@ -9,18 +9,37 @@
"bin": {
"island": "./bin/island.js"
},
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/node/index.js"
},
"./dist/*": "./dist/*",
"./package.json": "./package.json",
"./theme": {
"types": "./dist/index.d.ts",
"default": "./src/client/theme-default/index.ts"
}
},
"scripts": {
"dev": "tsup --watch",
"build": "tsup --minify && tsx scripts/pre-bundle.cts",
"start:client": "cd src/client && tsc -w",
"start:node": "cd src/node && tsc -w",
"dev:docs": "node ./bin/island docs",
"build:docs": "pnpm build && node ./bin/island build docs",
"build:docs": "node ./bin/island build docs",
"start:docs": "node ./bin/island start docs",
"lint:fix": "eslint --fix --ext .js,.jsx,.ts,.tsx --quiet ./",
"test": "vitest run",
"prepublishOnly": "pnpm build"
},
"keywords": ["vite", "ssg", "island architecture", "docs", "framework"],
"keywords": [
"vite",
"ssg",
"island architecture",
"docs",
"framework"
],
"author": "Sanyuan0704",
"license": "MIT",
"dependencies": {
Expand All @@ -36,6 +55,7 @@
"@vitejs/plugin-react": "2.0.1",
"acorn": "^8.8.0",
"cac": "6.7.12",
"compression": "^1.7.4",
"debug": "^4.3.4",
"esbuild": "0.15.5",
"fast-glob": "3.2.11",
Expand All @@ -44,7 +64,10 @@
"hast": "^1.0.0",
"hast-util-from-html": "^1.0.0",
"lodash-es": "^4.17.21",
"mdast-util-mdxjs-esm": "^1.3.0",
"ora": "^6.1.2",
"picocolors": "^1.0.0",
"polka": "^0.5.2",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-router-dom": "^6.3.0",
Expand All @@ -55,29 +78,29 @@
"remark-frontmatter": "^4.0.1",
"remark-gfm": "^3.0.1",
"remark-mdx-frontmatter": "^2.0.3",
"unist-util-visit-children": "^2.0.0",
"vite": "^3.0.9",
"mdast-util-mdxjs-esm": "^1.3.0",
"ora": "^6.1.2",
"shiki": "^0.11.1",
"sirv": "^2.0.2",
"unified": "^10.1.2",
"unist-util-visit": "^4.1.1",
"unist-util-visit-children": "^2.0.0",
"vite": "^3.0.9",
"vite-plugin-chunk-split": "^0.3.0",
"vite-plugin-inspect": "^0.6.1",
"shiki": "^0.11.1"
"vite-plugin-inspect": "^0.6.1"
},
"devDependencies": {
"@leafac/rehype-shiki": "^2.1.2",
"@loadable/babel-plugin": "^5.13.2",
"@types/babel__core": "^7.1.19",
"@types/babel__helper-plugin-utils": "^7.10.0",
"@types/babel__traverse": "^7.18.1",
"@types/compression": "^1.7.2",
"@types/fs-extra": "^9.0.13",
"@types/github-slugger": "^1.3.0",
"@types/hast": "^2.3.4",
"@types/koa": "^2.13.5",
"@types/koa-router": "^7.4.4",
"@types/loadable__component": "^5.13.4",
"@types/lodash-es": "^4.17.6",
"@types/polka": "^0.5.4",
"@types/react": "^18.0.17",
"@types/react-dom": "^18.0.6",
"@types/resolve": "^1.20.2",
Expand Down

0 comments on commit c8bd1fe

Please sign in to comment.