0.2.0 • Published 1 month ago

@urban-ui/arc v0.2.0

Weekly downloads
-
License
MIT
Repository
github
Last release
1 month ago

arc

Builds urban-ui packages

Getting started

Arc is a bun script that uses watchman to react to file changes.

npm add -D @urban-ui/arc
  • Add a package script
"scripts": {
  "build": "arc build"
}
  • Run arc
npm run build

By default arc will compile all files under an src directory and output them to dist. It will also generate typescript definition files based on the tsconfig.json found in the package.

Arc can be configured by placing an arc.config.ts file (or json, or js) at the package root, for example:

import type {Config} from '@urban-ui/arc'
import tsconfig from './tsconfig.json'

const config: Config = {
  include: [tsconfig.compilerOptions.rootDir],
  outDir: 'dist',
  rootDir: tsconfig.compilerOptions.rootDir,
}

export default config

Local development

To install dependencies:

bun install

To run:

bun run rk.ts

To run with verbose console output use the debug environment variable:

DEBUG=* bun run rk.ts

Running against the test example package is usually a safe bet:

cd __tests__/base
bun run ../../rk.ts build