Skip to content

Commit c6a4d97

Browse files
committed
fix: updated readme
1 parent e5e9d9c commit c6a4d97

File tree

1 file changed

+25
-31
lines changed

1 file changed

+25
-31
lines changed

README.md

Lines changed: 25 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,8 @@
11
# PostCSS Angular Inline
22

3-
## Overview
4-
53
A [PostCSS](https://github.com/postcss/postcss) syntax plugin to process inline CSS styles in Angular components, enabling the use of PostCSS transformations and Stylelint.
64

7-
**Current Version:** `0.1.0`
8-
9-
## Usage with PostCSS
10-
11-
1. Install via npm:
12-
13-
```bash
14-
npm install --save-dev postcss-angular-inline
15-
```
16-
17-
2. Configure PostCSS:
18-
19-
```javascript
20-
// postcss.config.js
21-
module.exports = {
22-
syntax: "postcss-angular-inline",
23-
plugins: [
24-
// Your PostCSS plugins
25-
],
26-
};
27-
```
5+
> **Note:** Generally, you don't need a syntax plugin for Angular unless you're using inline styles. It's common practice to generate styles outside of the component, but if you choose to use inline styles, this plugin enables PostCSS transformations and Stylelint integration.
286
297
## Usage with Stylelint
308

@@ -39,19 +17,15 @@ To use Stylelint with this syntax plugin and confine linting to only .component.
3917
2. Create a .stylelintrc.json Configuration File
4018

4119
```json
42-
// .stylelintrc.json
4320
{
4421
"extends": ["stylelint-config-standard"],
4522
"overrides": [
4623
{
4724
"files": ["**/*.component.ts"],
48-
"customSyntax": "postcss-angular-inline",
49-
"rules": {
50-
// Your Stylelint rules
51-
},
52-
},
53-
],
54-
};
25+
"customSyntax": "postcss-angular-inline"
26+
}
27+
]
28+
}
5529
```
5630

5731
3. Run Stylelint on .component.ts Files
@@ -60,6 +34,26 @@ To use Stylelint with this syntax plugin and confine linting to only .component.
6034
npx stylelint "**/*.component.ts"
6135
```
6236

37+
## Usage with PostCSS
38+
39+
1. Install via npm:
40+
41+
```bash
42+
npm install --save-dev postcss-angular-inline
43+
```
44+
45+
2. Configure PostCSS:
46+
47+
```javascript
48+
// postcss.config.js
49+
module.exports = {
50+
syntax: "postcss-angular-inline",
51+
plugins: [
52+
// Your PostCSS plugins
53+
],
54+
};
55+
```
56+
6357
## Roadmap to Version 1.0.0
6458

6559
The following features and improvements are planned before the official 1.0.0 release:

0 commit comments

Comments
 (0)