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

nap

Package Overview
Dependencies
Maintainers
1
Versions
46
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nap - npm Package Compare versions

Comparing version 0.3.5 to 0.4.1

test/fixtures/bad/bad_coffee.coffee

5

package.json
{
"name": "nap",
"version": "0.3.5",
"version": "0.4.1",
"author": "Craig Spaeth <craigspaeth@gmail.com> (http://craigspaeth.com)",

@@ -19,3 +19,4 @@ "description": "Compile and package your assets including stylesheets, javascripts, and client-side javascript templates for node.js",

"engines": {
"node": ">= 0.4.0"
"node": "0.6.x",
"npm": "1.1.x"
},

@@ -22,0 +23,0 @@ "dependencies": {

@@ -7,3 +7,3 @@ # Node Asset Packager

Declare asset packages
### 1. Declare asset packages

@@ -38,3 +38,3 @@ ````javascript

Include packages in your views by calling one of nap's helpers. (example in [jade](https://github.com/visionmedia/jade))
### 2. Include packages in your views by calling one of nap's helpers. (example in [jade](https://github.com/visionmedia/jade))

@@ -54,19 +54,4 @@ ````jade

Concatenate & minify once for production
Assets will be compiled and output on every request in development, and concatenated/minified/gzipped once upon initialization in production. Some express.js based examples can be found in the [examples folder](https://github.com/craigspaeth/nap/tree/master/examples).
````javascript
nap({
mode: 'production',
assets: {
js: //...
css: //...
jst: //...
}
});
nap.package();
````
Some express.js based examples can be found in the [examples folder](https://github.com/craigspaeth/nap/tree/master/examples).
## Installation

@@ -78,3 +63,3 @@

To make things easy nap assumes you have a */public* folder to serve static assets (like an Express.js or Ruby on Rails public folder) so that nap can generate & reference assets inside */public/assets*.
To make things easy nap assumes you have a */public* folder to serve static assets (like an Express.js public folder) so that nap can generate & reference assets inside */public/assets*.

@@ -191,3 +176,3 @@ Simply pass a set of options to the main `nap` function to configure your asset packages. Then use one of nap's helpers (`nap.js('package-name')`, `nap.css('package-name')`, `nap.jst('package-name')`) to output `<script>` and `<style> ` tags into your server-side templates.

In production use the `nap.package()` function once (e.g. upon deployment).
In production nap will call `nap.package()` upon initialization (aka. calling `nap({ assets: ..., mode: 'production' })`).

@@ -194,0 +179,0 @@ Calling `nap.package()` will concatenate all of the files, minify, and finally output the result to a single package file (e.g. *public/assets/package-name.js*).

lib/nap.coffee

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