-
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.
Migrate from TSDX to publishing untranspiled .ts source files (#587)
- Loading branch information
Showing
35 changed files
with
1,322 additions
and
6,172 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
{} | ||
{ | ||
"buildCommand": false | ||
} |
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 was deleted.
Oops, something went wrong.
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 |
---|---|---|
|
@@ -4,7 +4,6 @@ node_modules | |
dist | ||
|
||
__tests__/fixtures/__temp | ||
docker/clone-and-preflight.js | ||
|
||
*.tsbuildinfo | ||
|
||
|
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
|
@@ -6,6 +6,10 @@ const fixturesTempDir = '__tests__/fixtures/__temp'; | |
|
||
beforeAll( | ||
async () => { | ||
// Pack and install Preflight globally | ||
const { stdout: pnpmPackTarballPath } = await execa`pnpm pack`; | ||
await execa`pnpm add --global ${process.cwd()}/${pnpmPackTarballPath}`; | ||
|
||
await pMap( | ||
[ | ||
{ | ||
|
@@ -60,7 +64,7 @@ function sortStdoutAndStripVersionNumber(stdout: string) { | |
test('Passes in the react-passing test project', async () => { | ||
const { stdout, stderr } = await execa({ | ||
Check failure on line 65 in __tests__/e2e.test.ts GitHub Actions / windows-latest: Build, lint, test__tests__/e2e.test.ts > Passes in the react-passing test project
|
||
cwd: `${fixturesTempDir}/react-passing`, | ||
})`${process.cwd()}/bin/preflight.js`; | ||
})`preflight`; | ||
|
||
expect(sortStdoutAndStripVersionNumber(stdout)).toMatchSnapshot(); | ||
expect(stderr.replace(/^\(node:\d+\) /, '')).toMatchSnapshot(); | ||
|
@@ -69,7 +73,7 @@ test('Passes in the react-passing test project', async () => { | |
test('Passes in the next-js-passing test project', async () => { | ||
const { stdout, stderr } = await execa({ | ||
Check failure on line 74 in __tests__/e2e.test.ts GitHub Actions / windows-latest: Build, lint, test__tests__/e2e.test.ts > Passes in the next-js-passing test project
|
||
cwd: `${fixturesTempDir}/next-js-passing`, | ||
})`${process.cwd()}/bin/preflight.js`; | ||
})`preflight`; | ||
|
||
expect(sortStdoutAndStripVersionNumber(stdout)).toMatchSnapshot(); | ||
expect(stderr.replace(/^\(node:\d+\) /, '')).toMatchSnapshot(); | ||
|
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env -S pnpm exec tsx | ||
|
||
import '../src/index.ts'; |
This file was deleted.
Oops, something went wrong.
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 was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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,6 +1,6 @@ | ||
{ | ||
"name": "@upleveled/preflight", | ||
"version": "7.0.9", | ||
"version": "8.0.0-0", | ||
"repository": "upleveled/preflight", | ||
"license": "MIT", | ||
"author": "UpLeveled (https://github.com/upleveled)", | ||
|
@@ -9,28 +9,21 @@ | |
"Karl Horky <[email protected]>" | ||
], | ||
"type": "module", | ||
"main": "dist/preflight.esm.js", | ||
"module": "dist/preflight.esm.js", | ||
"typings": "dist/index.d.ts", | ||
"module": "./src/index.ts", | ||
"types": "./src/index.ts", | ||
"bin": { | ||
"preflight": "bin/preflight.js" | ||
"preflight": "./bin/preflight.ts" | ||
}, | ||
"files": [ | ||
"bin/preflight.js", | ||
"dist", | ||
"./bin/preflight.js", | ||
"src" | ||
], | ||
"scripts": { | ||
"analyze": "size-limit --why", | ||
"build": "tsdx build --format esm --target node --tsconfig tsconfig.src.json", | ||
"docker-build": "docker build --tag preflight .", | ||
"docker-build-run": "pnpm docker-build-ts && pnpm docker-build && pnpm docker-run", | ||
"docker-build-ts": "tsc --project docker/tsconfig.build.json", | ||
"docker-build-run": "pnpm docker-build && pnpm docker-run", | ||
"docker-run": "docker run preflight", | ||
"lint": "eslint . --max-warnings 0", | ||
"prepare": "pnpm build", | ||
"size": "size-limit", | ||
"start": "tsdx watch --format esm --target node", | ||
"start": "tsx watch ./src/index.ts", | ||
"test": "vitest run", | ||
"test-local": "rm -rf ./__tests__/fixtures/__temp && pnpm test" | ||
}, | ||
|
@@ -47,44 +40,23 @@ | |
"p-reduce": "3.0.0", | ||
"readdirp": "4.0.2", | ||
"semver": "7.6.3", | ||
"top-user-agents": "2.1.24" | ||
"top-user-agents": "2.1.24", | ||
"tsx": "4.19.1" | ||
}, | ||
"devDependencies": { | ||
"@size-limit/file": "11.1.6", | ||
"@types/node": "22.7.5", | ||
"@types/p-map": "2.0.0", | ||
"@types/semver": "7.5.8", | ||
"eslint": "9.12.0", | ||
"eslint-config-upleveled": "8.7.3", | ||
"eslint-config-upleveled": "8.8.0", | ||
"p-map": "7.0.2", | ||
"postinstall-postinstall": "2.1.0", | ||
"prettier": "3.3.3", | ||
"size-limit": "11.1.6", | ||
"stylelint": "16.9.0", | ||
"tsdx": "0.14.1", | ||
"tslib": "2.7.0", | ||
"typescript": "5.6.3", | ||
"vitest": "2.1.2" | ||
}, | ||
"packageManager": "[email protected]+sha512.e5a7e52a4183a02d5931057f7a0dbff9d5e9ce3161e33fa68ae392125b79282a8a8a470a51dfc8a0ed86221442eb2fb57019b0990ed24fab519bf0e1bc5ccfc4", | ||
"engines": { | ||
"node": ">=18" | ||
}, | ||
"pnpm": { | ||
"overrides": { | ||
"@typescript-eslint/eslint-plugin": "8.8.1", | ||
"@typescript-eslint/parser": "8.8.1", | ||
"@typescript-eslint/scope-manager": "8.8.1", | ||
"@typescript-eslint/utils": "8.8.1", | ||
"eslint": "9.12.0", | ||
"eslint-plugin-jest": "28.8.3", | ||
"eslint-plugin-react-hooks": "4.6.2", | ||
"node-notifier": "10.0.1", | ||
"[email protected]>semver": "5.7.2", | ||
"jest": "30.0.0-alpha.6", | ||
"rollup-plugin-typescript2": "^0.36.0", | ||
"ts-jest": "29.2.5", | ||
"typescript": "5.6.3" | ||
} | ||
} | ||
} |
Oops, something went wrong.