@microflash/preset
Advanced tools
Comparing version
{ | ||
"name": "@microflash/preset", | ||
"version": "0.7.0", | ||
"version": "0.7.1", | ||
"description": "A modern CSS preset", | ||
@@ -26,4 +26,3 @@ "keywords": [ | ||
"postcss-cli": "^10.1.0", | ||
"postcss-combine-duplicated-selectors": "^10.0.3", | ||
"postcss-preset-env": "^8.1.0", | ||
"postcss-preset-env": "^8.3.0", | ||
"sass": "^1.60.0" | ||
@@ -30,0 +29,0 @@ }, |
const postcssPresetEnv = require("postcss-preset-env") | ||
const postcssCombineDuplicatedSelectors = require("postcss-combine-duplicated-selectors") | ||
@@ -17,4 +16,3 @@ module.exports = (ctx) => ({ | ||
}), | ||
postcssCombineDuplicatedSelectors(), | ||
] | ||
}) |
@@ -13,2 +13,4 @@  | ||
- [Use](#use) | ||
- [Browser support](#browser-support) | ||
- [Decisions](#decisions) | ||
- [Credits](#credits) | ||
@@ -44,8 +46,39 @@ - [License](#license) | ||
In Node.js or Deno, importing the CSS in the entrypoint file of your application should include the `@microflash/preset` in the final CSS bundle. Make sure that this is the first CSS import before including any other CSS files. | ||
In Node.js or Deno, import the CSS in the entrypoint file of your application. | ||
If you're using Sass, use `https://unpkg.com/@microflash/preset/src/preset.scss` in the main Sass file before any other rules. | ||
```js | ||
import "@microflash/preset" | ||
// or using URL import | ||
import "https://unpkg.com/@microflash/preset" | ||
``` | ||
Make sure that this is the first CSS import before including any other CSS files. | ||
If you're using Sass, you can import Sass file instead of the compiled version. This is useful if you want to compile the CSS for custom browser targets. | ||
You can import the Sass file in the entrypoint of your application as follows. | ||
```js | ||
import "@microflash/preset/scss" | ||
// or using URL import | ||
import "https://unpkg.com/@microflash/preset/src/preset.scss" | ||
``` | ||
Alternatively, you can import it in your main Sass file before any other rules. | ||
```scss | ||
@use "@microflash/preset/scss"; | ||
// rest of the Sass imports | ||
``` | ||
In browser, including the `<link>` before any other stylesheet should do the trick. | ||
## Browser support | ||
`preset` supports [evergreen browsers](https://browsersl.ist/#q=defaults%2C+not+IE+%3E+0). | ||
## Decisions | ||
The rationale behind the decisions for the `preset` are available as ADRs (Any Decision Records) under [decisions](./docs/decisions/). | ||
## Credits | ||
@@ -52,0 +85,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
28467
2.43%5
-16.67%92
55.93%170
-0.58%