Skip to content

Commit 244a143

Browse files
committed
chore: package output into dist
1 parent 8443e22 commit 244a143

10 files changed

Lines changed: 16 additions & 14 deletions

File tree

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@ node_modules
33
coverage
44
*.log
55
.eslintcache
6+
*.tsbuildinfo
67
build
8+
dist
79
.idea
810
.DS_Store
911

agents/build-and-validation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
- `yarn lint` runs ESLint on `src`.
1717
- `yarn validate` runs typecheck, tests, lint, and Prettier checks for the main package.
18-
- `yarn build` cleans `build/`, transpiles source with Babel, and emits TypeScript declarations.
18+
- `yarn build` cleans `dist/`, transpiles source with Babel, and emits TypeScript declarations.
1919

2020
## Repo layout
2121

eslint.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ const patchedCallstackConfig = callstackConfig.map((configItem) => {
2222

2323
export default [
2424
{
25-
ignores: ['build/', 'experiments-rtl/', 'website/', 'eslint.config.mjs', 'jest-setup.ts'],
25+
ignores: ['dist/', 'experiments-rtl/', 'website/', 'eslint.config.mjs', 'jest-setup.ts'],
2626
},
2727
...patchedCallstackConfig,
2828
...tseslint.configs.strict,

jest.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
module.exports = {
22
preset: 'react-native',
33
setupFilesAfterEnv: ['./jest-setup.ts'],
4-
testPathIgnorePatterns: ['build/', 'examples/', 'experiments-app/', 'codemods/'],
4+
testPathIgnorePatterns: ['dist/', 'examples/', 'experiments-app/', 'codemods/'],
55
testTimeout: 60000,
66
transformIgnorePatterns: ['/node_modules/(?!(@react-native|react-native)/).*/'],
77
snapshotSerializers: ['@relmify/jest-serializer-strip-ansi/always'],

matchers.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export * from './build/matchers';
1+
export * from './dist/matchers';

matchers.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
// makes it so people can import from '@testing-library/react-native/pure'
2-
module.exports = require('./build/matchers');
1+
// makes it so people can import from '@testing-library/react-native/matchers'
2+
module.exports = require('./dist/matchers');

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
"name": "@testing-library/react-native",
33
"version": "14.0.0-rc.1",
44
"description": "Simple and complete React Native testing utilities that encourage good testing practices.",
5-
"main": "build/index.js",
6-
"types": "build/index.d.ts",
5+
"main": "dist/index.js",
6+
"types": "dist/index.d.ts",
77
"repository": {
88
"type": "git",
99
"url": "https://www.github.com/callstack/react-native-testing-library.git"
@@ -23,7 +23,7 @@
2323
"integration"
2424
],
2525
"scripts": {
26-
"clean": "del build",
26+
"clean": "del dist",
2727
"test": "jest",
2828
"test:ci": "jest --maxWorkers=2",
2929
"test:ci:coverage": "jest --maxWorkers=2 --collectCoverage=true",
@@ -39,15 +39,15 @@
3939
"validate:examples": "yarn --cwd examples/basic validate && yarn --cwd examples/cookbook validate",
4040
"validate:all": "yarn validate && yarn validate:examples && yarn docs:check && yarn --cwd website validate && yarn --cwd experiments-app validate",
4141
"validate:fix": "yarn prettier:fix && yarn lint --fix && yarn typecheck && yarn test -u && docs:generate",
42-
"build:js": "babel src --out-dir build --extensions \".js,.ts,.jsx,.tsx\" --source-maps --ignore \"**/__tests__/**\"",
42+
"build:js": "babel src --out-dir dist --extensions \".js,.ts,.jsx,.tsx\" --source-maps --ignore \"**/__tests__/**\"",
4343
"build:ts": "tsc --build tsconfig.release.json",
4444
"build": "yarn clean && yarn build:js && yarn build:ts",
4545
"release": "release-it",
4646
"release:next": "release-it --preRelease=rc --npm.tag=next",
4747
"release:codemods": "yarn test:codemods && yarn dlx codemod@latest publish codemods/v14-async-functions && yarn dlx codemod@latest publish codemods/v14-update-deps"
4848
},
4949
"files": [
50-
"build/",
50+
"dist/",
5151
"matchers.js",
5252
"matchers.d.ts",
5353
"pure.js",

pure.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export * from './build/pure';
1+
export * from './dist/pure';

pure.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
// makes it so people can import from '@testing-library/react-native/pure'
2-
module.exports = require('./build/pure');
2+
module.exports = require('./dist/pure');

tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"noEmit": true,
1414
"rootDir": "src",
1515
"types": ["jest", "node"],
16-
"outDir": "build"
16+
"outDir": "dist"
1717
},
1818
"include": ["src/**/*"],
1919
"exclude": ["src/__tests__/react-19_2/**/*"]

0 commit comments

Comments
 (0)