Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

carrot-css

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

carrot-css - npm Package Compare versions

Comparing version 0.1.1 to 0.2.0

css/_layout_utilities.scss

48

.eleventy.js

@@ -5,16 +5,14 @@ const pluginSass = require("eleventy-plugin-sass")

const moment = require("moment")
const { fstat } = require("fs")
module.exports = function (eleventyConfig) {
// design images
// eleventyConfig.addPassthroughCopy({ public: 'public' })
// eleventyConfig.addPassthroughCopy('_dist')
// eleventyConfig.addCollection('sortedGallery', function (collectionApi) {
// return collectionApi.getFilteredByTag('gallery').sort(function (a, b) {
// return b.data.date - a.data.date
// })
// })
eleventyConfig.addPlugin(pluginSass, {
watch: ["css/*.css", "css/*.scss", "css/**/*.css", "css/**/*.scss"],
watch: [
"css/*.css",
"css/*.scss",
"css/**/*.css",
"css/**/*.scss",
"docs/css/*.scss",
"docs/css/*.css",
],
sourcemaps: true,

@@ -24,23 +22,11 @@ outputDir: "docs/_site/css/",

eleventyConfig.addWatchTarget("css")
eleventyConfig.addWatchTarget("*.njk")
eleventyConfig.addWatchTarget("./css/")
// eleventyConfig.addWatchTarget("**.njk")
// eleventyConfig.addWatchTarget("**.html")
// eleventyConfig.addWatchTarget("**.md")
eleventyConfig.addWatchTarget("docs/index.html")
eleventyConfig.addWatchTarget("docs/test.njk")
eleventyConfig.addFilter("console", function (value) {
return util.inspect(value)
})
// eleventyConfig.addFilter('console', function (value) {
// return util.inspect(value)
// })
// eleventyConfig.addFilter('getPageBySlug', function (collection, slug) {
// let item = collection.find(function (item) {
// return item.data.page.fileSlug == slug
// })
// return item ? item.data : null
// })
// eleventyConfig.addFilter('formatDate', function (date) {
// return moment(date).format('DD.MM.YYYY')
// })
return {

@@ -53,4 +39,4 @@ dir: {

},
templateFormats: ["html", "njk"],
templateFormats: ["html", "njk", "md"],
}
}

@@ -27,4 +27,4 @@ const chalk = require("chalk")

} else if (args[0] == "compile") {
compileCSS("_dist/carrot-css.css")
compileCSS("_dist/carrot-css.min.css", true)
compileCSS("css/carrot.scss", "dist/carrot.css")
compileCSS("css/carrot.scss", "dist/carrot.min.css", true)
} else {

@@ -31,0 +31,0 @@ console.log(

{
"name": "carrot-css",
"version": "0.1.1",
"version": "0.2.0",
"description": "A simple CSS starter, that assume as less as possible",
"main": "index.js",
"main": "./dist/carrot.css",
"style": "./dist/carrot.css",
"author": "Tom Quinonero <tomquinonero@hey.com>",

@@ -21,2 +22,3 @@ "license": "MIT",

"figlet": "^1.5.0",
"filesize": "^6.1.0",
"minimist": "^1.2.5",

@@ -23,0 +25,0 @@ "modern-css-reset": "^1.4.0",

var fs = require("fs")
const chalk = require("chalk")
var filesize = require("filesize")

@@ -8,5 +9,5 @@ const sass = require("sass")

module.exports = (outputPath, minimize = false) => {
module.exports = (inputPath, outputPath, minimize = false) => {
var result = sass.renderSync({
file: "css/main.scss",
file: inputPath,
outputStyle: minimize ? "compressed" : "expanded",

@@ -25,5 +26,16 @@ })

console.log(chalk.green(`🎉 G O O D N E W S 🎉\n`))
console.log(chalk.green(`🎉 CSS built under ${outputPath}\n\n\n`))
console.log(chalk.green(`🎉 CSS built under ${outputPath}\n`))
const stats = fs.statSync(outputPath)
const fileSizeInKb = filesize(stats.size, { round: 0 })
// we write the building size in a file to be displayed in the documentation
console.log(chalk.green(`File size: ${fileSizeInKb}\n\n\n\n`))
if (minimize) {
fs.writeFile(
"./docs/_data/libSize.json",
`{"libSize": "${fileSizeInKb}"}`,
() => {}
)
}
})
})
}

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

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc