A build tool created on top of Roolup. For TypeScript and React Typescript to .JS
Install the package: npm i ptah -D
or yarn add ptah -D
- Add conguration in your package.json
{
"exports": {
".": {
"import": "./dist/index.module.js",
"require": "./dist/index.js"
},
"./package.json": "./package.json"
},
"main": "dist/index.js",
"module": "dist/index.module.js",
"source": "src/index.ts",
"types": "./dist/@types/index.d.ts",
"files": [
"dist"
],
}
NOTE: Change
"src/index.tsx"
for tsx.
- Execute:
ptah
on terminal.
Add two scripts on package.json:
{
"scripts": {
"build": "ptah",
"dev": "ptah-dev"
}
}
Use yarn dev
(aka. ptah-dev
) to watch changes and build for every change.
Ptah /ˈtɑː/[1] (Ancient Egyptian: ptḥ, reconstructed [piˈtaħ]; Ancient Greek: Φθά; Coptic: ⲡⲧⲁϩ)[2] is an ancient Egyptian deity, the god of craftsmen and architects.
...and it's also is path, misspelled 🙃