Skip to content

Commit

Permalink
refactor: rename source to map to existing output files
Browse files Browse the repository at this point in the history
  • Loading branch information
chaance committed Oct 11, 2022
1 parent 81cc3b0 commit be9438a
Show file tree
Hide file tree
Showing 93 changed files with 156 additions and 117 deletions.
4 changes: 2 additions & 2 deletions packages/accordion/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-accordion.tsx",
"types": "./src/reach-accordion.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/accordion/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/accordion/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig(`src/reach-accordion.tsx`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/alert-dialog/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-alert-dialog.tsx",
"types": "./src/reach-alert-dialog.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/alert-dialog/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/alert-dialog/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig("src/reach-alert-dialog.tsx", {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/alert/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-alert.tsx",
"types": "./src/reach-alert.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/alert/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/alert/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig(`src/reach-alert.tsx`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/auto-id/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-auto-id.ts",
"types": "./src/reach-auto-id.ts",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/auto-id/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/auto-id/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig("src/reach-auto-id.ts", {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/checkbox/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-checkbox.ts",
"types": "./src/reach-checkbox.ts",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
File renamed without changes.
7 changes: 5 additions & 2 deletions packages/checkbox/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig("src/reach-checkbox.ts", {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/combobox/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-combobox.tsx",
"types": "./src/reach-combobox.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/combobox/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/combobox/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig(`src/reach-combobox.tsx`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/descendants/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-descendants.tsx",
"types": "./src/reach-descendants.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/descendants/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/descendants/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig(`src/reach-descendants.tsx`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/dialog/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-dialog.tsx",
"types": "./src/reach-dialog.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/dialog/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/dialog/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig(`src/reach-dialog.tsx`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/disclosure/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-disclosure.tsx",
"types": "./src/reach-disclosure.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/disclosure/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/disclosure/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig(`src/reach-disclosure.tsx`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/dropdown/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-dropdown.tsx",
"types": "./src/reach-dropdown.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/dropdown/src/index.ts

This file was deleted.

File renamed without changes.
2 changes: 1 addition & 1 deletion packages/dropdown/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";
type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let cfg: TsupConfig = getTsupConfig(`src/reach-dropdown.tsx`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/listbox/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-listbox.tsx",
"types": "./src/reach-listbox.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/listbox/src/index.ts

This file was deleted.

2 changes: 1 addition & 1 deletion packages/listbox/src/machine.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { assign } from "@reach/machine";
import { getOwnerDocument } from "@reach/utils";

import type { ListboxDescendant, ListboxValue } from "./listbox";
import type { ListboxDescendant, ListboxValue } from "./reach-listbox";
import type { MachineEventWithRefs, StateMachine } from "@reach/machine";

////////////////////////////////////////////////////////////////////////////////
Expand Down
File renamed without changes.
7 changes: 5 additions & 2 deletions packages/listbox/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig(`src/reach-listbox.tsx`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/machine/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-machine.ts",
"types": "./src/reach-machine.ts",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/machine/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/machine/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig(`src/reach-machine.ts`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/menu-button/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@
"react-dom": "^16.8.0 || 17.x",
"react-is": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-menu-button.tsx",
"types": "./src/reach-menu-button.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/menu-button/src/index.ts

This file was deleted.

File renamed without changes.
2 changes: 1 addition & 1 deletion packages/menu-button/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";
type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let cfg: TsupConfig = getTsupConfig("src/reach-menu-button.tsx", {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/popover/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-popover.tsx",
"types": "./src/reach-popover.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/popover/src/index.ts

This file was deleted.

File renamed without changes.
7 changes: 5 additions & 2 deletions packages/popover/tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ import { getTsupConfig, getPackageInfo } from "@reach-internal/dev/tsup.js";

type TsupConfig = ReturnType<typeof defineConfig>;

let { name: packageName, version: packageVersion } = getPackageInfo(__dirname);
let cfg: TsupConfig = getTsupConfig("src/index.ts", {
let { name: packageName, version: packageVersion } = getPackageInfo(
// @ts-expect-error
__dirname
);
let cfg: TsupConfig = getTsupConfig(`src/reach-popover.tsx`, {
packageName,
packageVersion,
});
Expand Down
4 changes: 2 additions & 2 deletions packages/portal/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@
"react": "^16.8.0 || 17.x",
"react-dom": "^16.8.0 || 17.x"
},
"main": "./src/index.ts",
"types": "./src/index.ts",
"main": "./src/reach-portal.tsx",
"types": "./src/reach-portal.tsx",
"files": [
"CHANGELOG.md",
"LICENSE",
Expand Down
1 change: 0 additions & 1 deletion packages/portal/src/index.ts

This file was deleted.

File renamed without changes.
Loading

0 comments on commit be9438a

Please sign in to comment.