@salty-css/webpack 0.0.1-alpha.52 → 0.0.1-alpha.53
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -5
- package/package.json +2 -2
package/README.md
CHANGED
@@ -12,13 +12,22 @@ In the world of frontend dev is there anything saltier than CSS? Salty CSS is bu
|
|
12
12
|
|
13
13
|
## Get started
|
14
14
|
|
15
|
-
### TL;DR
|
16
|
-
|
17
15
|
- Initialize: `npx salty-css init [directory]`
|
18
16
|
- Create component: `npx salty-css generate [filePath]`
|
19
17
|
- Build: `npx salty-css build [directory]`
|
20
18
|
|
21
|
-
###
|
19
|
+
### Packages
|
20
|
+
|
21
|
+
- [React](#react) → `npm install @salty-css/react`
|
22
|
+
- [Next.js](#nextjs) → `npm install @salty-css/next`
|
23
|
+
- [Vite](#vite) → `npm install @salty-css/vite`
|
24
|
+
- [Webpack](https://www.npmjs.com/package/@salty-css/webpack) → `npm install @salty-css/webpack`
|
25
|
+
- [Core](https://www.npmjs.com/package/@salty-css/react) → `npm install @salty-css/core`
|
26
|
+
- [ESLint](https://www.npmjs.com/package/@salty-css/eslint-plugin-core) → `npm install @salty-css/eslint-plugin-core`
|
27
|
+
|
28
|
+
[View React example](#example-dynamic-form-with-react)
|
29
|
+
|
30
|
+
### Add Salty CSS to your project with `salty-css` CLI
|
22
31
|
|
23
32
|
#### Initialize Salty CSS for a project
|
24
33
|
|
@@ -45,7 +54,7 @@ To ease the pain of package updates all Salty CSS packages can be updated with `
|
|
45
54
|
|
46
55
|
#### Next.js
|
47
56
|
|
48
|
-
1. First check the instructions for React
|
57
|
+
1. First check the instructions for [React](#react)
|
49
58
|
2. For Next.js support install `npm i -D @salty-css/next`
|
50
59
|
3. Add Salty CSS plugin to next.js config
|
51
60
|
|
@@ -53,13 +62,17 @@ To ease the pain of package updates all Salty CSS packages can be updated with `
|
|
53
62
|
- **Next.js 14 and older:** In `next.config.js` add import for salty plugin `const { withSaltyCss } = require('@salty-css/next');` and then add `withSaltyCss` to wrap your nextConfig export like so `module.exports = withSaltyCss(nextConfig);`
|
54
63
|
|
55
64
|
4. Make sure that `salty.config.ts` and `next.config.ts` are in the same folder!
|
65
|
+
5. Build `saltygen` directory by running your app once or with cli `npx salty-css build [directory]`
|
66
|
+
6. Import global styles from `saltygen/index.css` to some global css file with `@import 'insert_path_to_index_css';`.
|
56
67
|
|
57
68
|
#### Vite
|
58
69
|
|
59
|
-
1. First check the instructions for React
|
70
|
+
1. First check the instructions for [React](#react)
|
60
71
|
2. For Vite support install `npm i -D @salty-css/vite`
|
61
72
|
3. In `vite.config` add import for salty plugin `import { saltyPlugin } from '@salty-css/vite';` and then add `saltyPlugin(__dirname)` to your vite configuration plugins
|
62
73
|
4. Make sure that `salty.config.ts` and `vite.config.ts` are in the same folder!
|
74
|
+
5. Build `saltygen` directory by running your app once or with cli `npx salty-css build [directory]`
|
75
|
+
6. Import global styles from `saltygen/index.css` to some global css file with `@import 'insert_path_to_index_css';`.
|
63
76
|
|
64
77
|
### Create components
|
65
78
|
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@salty-css/webpack",
|
3
|
-
"version": "0.0.1-alpha.
|
3
|
+
"version": "0.0.1-alpha.53",
|
4
4
|
"main": "./dist/index.js",
|
5
5
|
"module": "./dist/index.mjs",
|
6
6
|
"typings": "./dist/index.d.ts",
|
@@ -29,7 +29,7 @@
|
|
29
29
|
}
|
30
30
|
},
|
31
31
|
"dependencies": {
|
32
|
-
"@salty-css/core": "^0.0.1-alpha.
|
32
|
+
"@salty-css/core": "^0.0.1-alpha.53",
|
33
33
|
"webpack": ">=5.x"
|
34
34
|
}
|
35
35
|
}
|