support typescript config
This commit is contained in:
parent
cdf81b4f7e
commit
ba179d8472
@ -57,10 +57,10 @@ export default {
|
|||||||
|
|
||||||
The config file can be placed in these locations, relative to `package.json`:
|
The config file can be placed in these locations, relative to `package.json`:
|
||||||
|
|
||||||
- `updates.config.js`
|
- `updates.config.{js,ts,mjs,mts}`
|
||||||
- `updates.config.mjs`
|
- `.config/updates.{js,ts,mjs,mts}`
|
||||||
- `.config/updates.js`
|
|
||||||
- `.config/updates.mjs`
|
For typescript, your runtime needs to support it either natively or via a node loader.
|
||||||
|
|
||||||
### Config File Options
|
### Config File Options
|
||||||
|
|
||||||
|
@ -749,9 +749,13 @@ async function main() {
|
|||||||
try {
|
try {
|
||||||
({default: config} = await Promise.any([
|
({default: config} = await Promise.any([
|
||||||
"updates.config.js",
|
"updates.config.js",
|
||||||
|
"updates.config.ts",
|
||||||
"updates.config.mjs",
|
"updates.config.mjs",
|
||||||
|
"updates.config.mts",
|
||||||
".config/updates.js",
|
".config/updates.js",
|
||||||
|
".config/updates.ts",
|
||||||
".config/updates.mjs",
|
".config/updates.mjs",
|
||||||
|
".config/updates.mts",
|
||||||
].map(str => import(join(projectDir, ...str.split("/"))))));
|
].map(str => import(join(projectDir, ...str.split("/"))))));
|
||||||
} catch {}
|
} catch {}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user