Skip to content

Commit 5a89ae8

Browse files
committed
fix: paths
1 parent d857fea commit 5a89ae8

File tree

118 files changed

+373
-1633
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

118 files changed

+373
-1633
lines changed

β€Ž.github/workflows/published-test.ymlβ€Ž

Lines changed: 0 additions & 30 deletions
This file was deleted.

β€Ž.npmignoreβ€Ž

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# Exclude story files
2+
**/*.stories.tsx
3+
**/*.stories.ts
4+
**/*.stories.mdx
5+
6+
# Exclude test files
7+
**/*.test.tsx
8+
**/*.test.ts
9+
10+
# Exclude test directories
11+
**/__tests__/
12+
**/test/
13+
14+
# Exclude dist artifacts
15+
dist/
16+
src/dist/
17+
18+
# Exclude development files
19+
.storybook/
20+
storybook-static/
21+
integration/
22+
tests/
23+
*.log
24+
build-storybook.log
25+
.eslintcache
26+
tsconfig.tsbuildinfo
27+
*.tsbuildinfo
28+
29+
# Exclude source maps (not needed for pure TS)
30+
**/*.map
31+
32+
# Exclude node_modules
33+
node_modules/
34+
35+
# Exclude git files
36+
.git/
37+
.gitignore
38+
.gitattributes
39+
40+
# Exclude CI/CD
41+
.github/
42+
43+
# Exclude config files (not needed by consumers)
44+
vite.config.mts
45+
postcss.config.mjs
46+
eslint.config.mjs
47+
components.json
48+
tsconfig.json
49+
pnpm-lock.yaml
50+
.prettierrc*
51+
.prettierignore
52+
.editorconfig
53+
.releaserc.json
54+
.vscode/
55+
56+
# Exclude old package tarballs
57+
*.tgz
58+
59+
# Exclude docs (README and LICENSE are auto-included)
60+
CLAUDE.md
61+
*.md
62+
!README.md
63+

β€ŽREADME.mdβ€Ž

Lines changed: 26 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,16 @@ Add this to the top of your project's CSS file where you configure Tailwind:
3333

3434
**Note:** The `@reference` directive is required for Tailwind v4 to recognize Moonshine's custom utilities and make them available in your project.
3535

36-
### 3. Import Moonshine's Compiled CSS
36+
### 3. Import Moonshine's CSS
3737

3838
In your main app file (or root layout):
3939

4040
```ts
4141
import '@speakeasy-api/moonshine/moonshine.css'
4242
```
4343

44+
**Note:** Moonshine distributes as pure TypeScript, and Vite will process the CSS from source automatically.
45+
4446
### 4. Set up the Provider
4547

4648
Wrap your application in the `MoonshineConfigProvider` component:
@@ -52,7 +54,7 @@ import { MoonshineConfigProvider } from '@speakeasy-api/moonshine'
5254
</MoonshineConfigProvider>
5355
```
5456

55-
### 5. Configure Custom Fonts (Optional)
57+
### 6. Configure Custom Fonts (Optional)
5658

5759
Moonshine uses custom fonts (Diatype, Tobias). If you have licenses for these fonts, add them to your project:
5860

@@ -79,7 +81,7 @@ Moonshine uses custom fonts (Diatype, Tobias). If you have licenses for these fo
7981

8082
If you don't have these fonts, the design system will fall back to system fonts.
8183

82-
### 6. Use Components and Utilities
84+
### 7. Use Components and Utilities
8385

8486
```tsx
8587
import { Grid } from '@speakeasy-api/moonshine'
@@ -112,7 +114,7 @@ The types are automatically generated during the build process and include:
112114

113115
πŸ’‘ **Tip**: This prevents typos and helps you discover available utilities without leaving your editor!
114116

115-
The package is built with [vite](https://vitejs.dev/), and is distributed in both [ESM](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules) and [CommonJS](https://nodejs.org/api/modules.html#modules-commonjs) formats.
117+
The package is built with [vite](https://vitejs.dev/) and distributed as **pure TypeScript**. Consumers using Vite will transpile the TypeScript on-the-fly, eliminating the need for a separate build step when linking the library locally.
116118

117119
### Using Tailwind Merge
118120

@@ -206,8 +208,7 @@ import type { MoonshineClasses } from '@speakeasy-api/moonshine/types/utilities'
206208

207209
1. Clone the repository
208210
2. Run `pnpm install` to install the dependencies
209-
3. Run `pnpm build` to build the package
210-
4. Run `pnpm storybook` to start the storybook server
211+
3. Run `pnpm storybook` to start the storybook server
211212

212213
If you'd like to develop Moonshine in tandem with another app, you can follow the steps outlined below in the **Linking the library locally** section.
213214

@@ -264,18 +265,33 @@ Run `pnpm test` to run the tests.
264265

265266
### Linking the library locally
266267

267-
Run `pnpm build:watch` within Moonshine to build the library and watch for changes.
268+
Since Moonshine distributes as pure TypeScript, linking is much simpler - no build step required!
268269

269-
Then run `pnpm link ../path/to/moonshine` within the app that will use the library. For the registry `webapp` directory (assuming a standard cloning setup where `moonshine` is a sibling of the registry repo), it would be:
270+
1. **Link the library** from within your consuming app:
270271

271272
```bash
272273
pnpm link ../path/to/moonshine
273274
```
274275

275-
The lockfile file within your app should referenced the linked copy:
276+
For example, if `moonshine` is a sibling of your app directory:
277+
278+
```bash
279+
pnpm link ../moonshine
280+
```
281+
282+
2. **Start your dev server** - Vite will automatically transpile the TypeScript from the linked library.
283+
284+
The lockfile within your app should reference the linked copy:
276285

277286
```yaml
278287
'@speakeasy-api/moonshine':
279-
specifier: ^0.43.1
288+
specifier: ^2.0.0-alpha.1
280289
version: link:../../../../moonshine
281290
```
291+
292+
**Benefits of pure TypeScript distribution:**
293+
294+
- βœ… No need to run `tsc` in watch mode
295+
- βœ… No build conflicts between library and consumer
296+
- βœ… Instant updates when you change source files
297+
- βœ… Simpler development workflow

β€Žcomponents.jsonβ€Ž

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,5 @@
99
"baseColor": "neutral",
1010
"cssVariables": true,
1111
"prefix": ""
12-
},
13-
"aliases": {
14-
"components": "@/components",
15-
"utils": "@/lib/utils",
16-
"ui": "@/components/ui",
17-
"lib": "@/lib",
18-
"hooks": "@/hooks"
1912
}
20-
}
13+
}

β€Žintegration/integration.test.tsxβ€Ž

Lines changed: 0 additions & 118 deletions
This file was deleted.

β€Žintegration/package.jsonβ€Ž

Lines changed: 0 additions & 22 deletions
This file was deleted.

0 commit comments

Comments
Β (0)