Skip to content

Commit 1bb4e2e

Browse files
authored
Merge pull request #1 from ember-cli/fork
Fork the library
2 parents 9e65900 + ff13c9f commit 1bb4e2e

File tree

5 files changed

+6320
-4405
lines changed

5 files changed

+6320
-4405
lines changed

.github/workflows/ci.yml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- master
8+
pull_request: {}
9+
10+
concurrency:
11+
group: ci-${{ github.head_ref || github.ref }}
12+
cancel-in-progress: true
13+
14+
jobs:
15+
lint:
16+
runs-on: ubuntu-latest
17+
timeout-minutes: 5
18+
19+
steps:
20+
- uses: actions/checkout@v4
21+
- uses: pnpm/action-setup@v4
22+
- uses: actions/setup-node@v4
23+
with:
24+
node-version: 22
25+
cache: pnpm
26+
- run: pnpm i --frozen-lockfile
27+
- run: pnpm run lint
28+
29+
test:
30+
runs-on: ubuntu-latest
31+
timeout-minutes: 10
32+
33+
strategy:
34+
matrix:
35+
node-version: ['18.x', '20.x', '22.x']
36+
37+
steps:
38+
- uses: actions/checkout@v4
39+
- uses: pnpm/action-setup@v4
40+
- uses: actions/setup-node@v4
41+
with:
42+
node-version: ${{ matrix.node-version }}
43+
cache: pnpm
44+
- run: pnpm i --frozen-lockfile
45+
- run: pnpm test
46+
47+
floating:
48+
runs-on: ubuntu-latest
49+
timeout-minutes: 10
50+
51+
steps:
52+
- uses: actions/checkout@v4
53+
- uses: pnpm/action-setup@v4
54+
- uses: actions/setup-node@v4
55+
with:
56+
node-version: latest
57+
cache: pnpm
58+
- run: pnpm i --no-lockfile
59+
- run: pnpm test

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
1-
# `remove-types`
1+
# `babel-remove-types`
2+
3+
> [!NOTE]
4+
> This is a fork of https://github.com/cafreeman/remove-types. It's not marked as a fork because we want pull requests to target this repo and not "upstream".
25
36
A small library for transforming TypeScript code into JavaScript code in the least destructive way possible. This library exports a single function whose purpose is to preserve everything else about the code except for the actual TypeScript syntax itself. As a result, things like decorators and class fields should pass straight through without being transformed in any way.
47

58
## Usage
69

710
```js
8-
import { removeTypes } from 'remove-types';
11+
import { removeTypes } from 'babel-remove-types';
912

1013
const original = `
1114
type AnimalType = 'cat' | 'dog';

package.json

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
11
{
2-
"name": "remove-types",
3-
"author": "Chris Freeman",
4-
"version": "1.0.0",
2+
"name": "babel-remove-types",
3+
"contributors": [
4+
"Chris Freeman",
5+
"Chris Manson <[email protected]>"
6+
],
7+
"version": "0.0.0",
58
"license": "MIT",
69
"repository": {
710
"type": "git",
8-
"url": "https://github.com/cafreeman/remove-types"
11+
"url": "https://github.com/ember-cli/babel-remove-types"
912
},
1013
"keywords": [
1114
"typescript",
@@ -28,18 +31,20 @@
2831
"ts:cjs": "tsc -p ts/cjs.tsconfig.json",
2932
"ts:esm": "tsc -p ts/esm.tsconfig.json",
3033
"ts:typedefs": "tsc -p ts/types.tsconfig.json && mv defs/* . && rimraf defs",
31-
"ts:all": "yarn ts:esm && yarn ts:cjs && yarn ts:typedefs",
32-
"build": "yarn clean && yarn ts:all",
34+
"ts:all": "pnpm ts:esm && pnpm ts:cjs && pnpm ts:typedefs",
35+
"build": "pnpm clean && pnpm ts:all",
3336
"clean": "rimraf ./*.d.ts ./*.d.ts.map ./dist",
3437
"lint": "eslint src test",
35-
"prepublishOnly": "yarn test && yarn build",
36-
"postpublish": "yarn clean",
38+
"prepublishOnly": "pnpm test && pnpm build",
39+
"prepare": "pnpm build",
40+
"postpublish": "pnpm clean",
3741
"release": "release-it",
3842
"test": "jest",
3943
"test:watch": "jest --watch"
4044
},
4145
"devDependencies": {
4246
"@types/babel__core": "^7.1.18",
47+
"@types/babel__traverse": "^7.20.6",
4348
"@types/jest": "^27.4.0",
4449
"@typescript-eslint/eslint-plugin": "^5.10.0",
4550
"@typescript-eslint/parser": "^5.10.0",
@@ -60,5 +65,6 @@
6065
},
6166
"release-it": {
6267
"github": true
63-
}
68+
},
69+
"packageManager": "[email protected]+sha512.0a203ffaed5a3f63242cd064c8fb5892366c103e328079318f78062f24ea8c9d50bc6a47aa3567cabefd824d170e78fa2745ed1f16b132e16436146b7688f19b"
6470
}

0 commit comments

Comments
 (0)