-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from phshy0607/fix-types
Fix types
- Loading branch information
Showing
6 changed files
with
47 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,26 @@ | ||
{ | ||
"name": "@blizzbolts/docit", | ||
"version": "0.6.5", | ||
"version": "0.6.6", | ||
"license": "MIT", | ||
"bin": { | ||
"docit": "bin/docit.js" | ||
}, | ||
"types": "./build/index.d.ts", | ||
"author": { | ||
"name": "phshy0607", | ||
"email": "[email protected]" | ||
}, | ||
"type": "module", | ||
"main": "./build/node/index.js", | ||
"module": "./build/node/index.js", | ||
"type": "module", | ||
"types": "./build/node/index.d.ts", | ||
"exports": { | ||
".": { | ||
"import": "./build/node/index.js", | ||
"types": "./build/node/index.d.ts" | ||
} | ||
}, | ||
"scripts": { | ||
"dev": "rm -rf build && run-p dev-node entry-prepare dev-client", | ||
"dev": "rimraf -rf build && run-p dev-node entry-prepare dev-client", | ||
"dev-node": "tsc -w -p src/node", | ||
"dev-client": "tsc -w -p src/client", | ||
"entry-prepare": "node scripts/cpEntryFile.js", | ||
|
@@ -21,10 +31,8 @@ | |
"docs": "run-p dev docs-dev", | ||
"docs-dev": "node ./bin/docit start", | ||
"docs-build": "node ./bin/docit build docs", | ||
"clean": "rm -rf node_modules build docs-dist", | ||
"test": "vitest", | ||
"publish:pages": "node scripts/gh.js", | ||
"release": "yarn build && yarn publish && yarn publish:pages" | ||
"release": "yarn build && yarn publish && node scripts/gh.js" | ||
}, | ||
"files": [ | ||
"build", | ||
|
@@ -34,9 +42,6 @@ | |
"scripts", | ||
"docs-dist" | ||
], | ||
"engines": { | ||
"node": ">=14" | ||
}, | ||
"devDependencies": { | ||
"@types/fs-extra": "^9.0.13", | ||
"@types/lodash-es": "^4.17.6", | ||
|
@@ -97,6 +102,9 @@ | |
"resolutions": { | ||
"react-is": "16.13.1" | ||
}, | ||
"engines": { | ||
"node": ">=14" | ||
}, | ||
"publishConfig": { | ||
"registry": "https://registry.npmjs.org", | ||
"access": "public" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,17 @@ | ||
import { createServer as createViteServer } from 'vite'; | ||
import { resolveConfig } from './config.js'; | ||
import { UserConfig } from './types.js'; | ||
import { docit } from './plugins/index.js'; | ||
import { createServer as createViteServer } from "vite"; | ||
import { resolveConfig } from "./config.js"; | ||
import { UserConfig } from "./types.js"; | ||
import { docit } from "./plugins/index.js"; | ||
|
||
export const start = async (userConfig: UserConfig) => { | ||
const config = await resolveConfig(userConfig, 'start'); | ||
const config = await resolveConfig(userConfig, "start"); | ||
return createViteServer({ | ||
base: '/', | ||
base: "/", | ||
plugins: [await docit(config)], | ||
}); | ||
}) | ||
.then((s) => s.listen()) | ||
.then((s) => { | ||
s.printUrls(); | ||
return s; | ||
}); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters