diff --git a/packages/README.md b/packages/README.md index 67d1e54d..eba9ee7c 100644 --- a/packages/README.md +++ b/packages/README.md @@ -2,4 +2,5 @@ - `tuono-vite`: Handles the bundling (with chunk splitting) - `tuono-routes-generator`: Handles the creation of the `routeGen.tree.ts` file -- `tuono-router`: Expose all the Functions and Component related to the routing +- `tuono-router`: Expose all the Functions and Components related to the routing +- `tuono`: Collect and expose all the public APIs. Is the only published package diff --git a/packages/tuono-router/package.json b/packages/tuono-router/package.json new file mode 100644 index 00000000..026c910e --- /dev/null +++ b/packages/tuono-router/package.json @@ -0,0 +1,12 @@ +{ + "name": "tuono-router", + "version": "1.0.0", + "description": "", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "keywords": [], + "author": "", + "license": "ISC" +} diff --git a/packages/tuono-router/src/index.ts b/packages/tuono-router/src/index.ts new file mode 100644 index 00000000..e69de29b diff --git a/packages/tuono-router/tsconfig.json b/packages/tuono-router/tsconfig.json new file mode 100644 index 00000000..01ad9218 --- /dev/null +++ b/packages/tuono-router/tsconfig.json @@ -0,0 +1,7 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "jsx": "react", + }, + "include": ["src", "tests", "vite.config.ts"], +} diff --git a/packages/tuono-router/vite.config.ts b/packages/tuono-router/vite.config.ts new file mode 100644 index 00000000..1c0b0d95 --- /dev/null +++ b/packages/tuono-router/vite.config.ts @@ -0,0 +1,21 @@ +import { defineConfig, mergeConfig } from 'vitest/config' +import { tanstackBuildConfig } from '@tanstack/config/build' +import react from '@vitejs/plugin-react' + +const config = defineConfig({ + plugins: [react()], + test: { + name: 'react-router', + watch: false, + environment: 'jsdom', + }, +}) + +export default mergeConfig( + config, + tanstackBuildConfig({ + entry: './src/index.tsx', + srcDir: './src', + }), +) +