Prefer the nodejs sass compiler
This commit is contained in:
parent
0536c8c35e
commit
de346f84b8
8 changed files with 392 additions and 128 deletions
15
README.md
15
README.md
|
@ -4,11 +4,12 @@ tail.css provides _a small subset_ of
|
|||
[tailwind](https://tailwindcss.com/)
|
||||
that has been extracted from a hobby project. A prebuilt copy of
|
||||
[dist/tail.css](dist/tail.css)
|
||||
is provided in case you don't have access to the Ruby sass compiler,
|
||||
is provided in case you don't have access to the nodejs sass compiler,
|
||||
along with a minimized copy
|
||||
([dist/tail.min.css](dist/tail.min.css)).
|
||||
There are compressed copies of those files included in
|
||||
[dist/](dist/) - they weigh in at around 6KB.
|
||||
There are gzip-compressed copies of those files included in
|
||||
[dist/](dist/)
|
||||
- `tail.css.min.gz`` weighs in at around 8.5KB.
|
||||
|
||||
## Why ?
|
||||
|
||||
|
@ -23,11 +24,17 @@ Custom builds provide a way to customize what features are
|
|||
included in a build. The `@import` directives in [src/](src/)
|
||||
decide what features to include:
|
||||
|
||||
$ npm install -g sass
|
||||
$ bin/build
|
||||
|
||||
## License
|
||||
|
||||
Copyright belongs to the
|
||||
Copyright of src/tail/ belongs to the
|
||||
[tailwind project](https://tailwindcss.com/).
|
||||
<br>
|
||||
See [tailwindcss/LICENSE](https://github.com/tailwindlabs/tailwindcss/blob/master/LICENSE).
|
||||
|
||||
Copyright of src/normalize/ belongs to the
|
||||
[normalize.css project](https://raw.githubusercontent.com/necolas/normalize.css).
|
||||
<br>
|
||||
See [normalize/LICENSE.md](https://github.com/necolas/normalize.css/blob/master/LICENSE.md).
|
||||
|
|
12
bin/build
12
bin/build
|
@ -1,13 +1,13 @@
|
|||
#!/bin/sh
|
||||
set -e
|
||||
if ! which sass > /dev/null 2>&1; then
|
||||
echo "No sass compiler found in \$PATH"
|
||||
compiler=$(which sass)
|
||||
if [ ${?} -ne 0 ]; then
|
||||
echo "The sass compiler was not found on \$PATH."
|
||||
exit 1
|
||||
else
|
||||
options="--no-cache --scss -r./shim.rb --sourcemap=none"
|
||||
set -e
|
||||
mkdir -p dist/
|
||||
sass ${options} --style expanded src/tail.scss dist/tail.css
|
||||
sass ${options} --style compressed src/tail.scss dist/tail.min.css
|
||||
${compiler} --embed-source-map --style expanded src/tail.scss dist/tail.css
|
||||
${compiler} --no-source-map --style compressed src/tail.scss dist/tail.min.css
|
||||
gzip -9 -k -f dist/tail.css
|
||||
gzip -9 -k -f dist/tail.min.css
|
||||
fi
|
||||
|
|
489
dist/tail.css
vendored
489
dist/tail.css
vendored
File diff suppressed because one or more lines are too long
BIN
dist/tail.css.gz
vendored
BIN
dist/tail.css.gz
vendored
Binary file not shown.
2
dist/tail.min.css
vendored
2
dist/tail.min.css
vendored
File diff suppressed because one or more lines are too long
BIN
dist/tail.min.css.gz
vendored
BIN
dist/tail.min.css.gz
vendored
Binary file not shown.
1
shim.rb
1
shim.rb
|
@ -1 +0,0 @@
|
|||
Fixnum = Integer unless defined?(Fixnum)
|
|
@ -1,3 +1,4 @@
|
|||
@import "normalize/index";
|
||||
@import "tail/height/index";
|
||||
@import "tail/width/index";
|
||||
@import "tail/margin/index";
|
||||
|
|
Loading…
Reference in a new issue