Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
asset-wrap
Advanced tools
wrap = require 'asset-wrap'
assets = wrap.AssetWrap [
new wrap.Stylus {
src: "#{__dirname}/path/to/app.styl"
dst: '/css/app.css'
compress: true
}
new wrap.Snockets {
src: "#{__dirname}/path/to/app.coffee"
dst: '/js/app.js'
compress: false
}
], {
AmazonS3:
key: ''
secret: ''
CloudFiles:
key: ''
secret: ''
}
assets.on 'complete', () ->
console.log 'assets compiled'
app.configure () ->
app.use assets.middleware
@get '/': ->
@render index: {
assets: assets
}
@view index: ->
head ->
@assets.tag '/css/app.css'
@assets.tag '/js/app.js'
# Wrap Single Asset - Wrap explicitly
wrap = require '../src/wrap'
asset = new wrap.Snockets {
src: "#{__dirname}/test.coffee"
dst: '/js/app.js'
}
asset.on 'complete', () ->
console.log asset.src
console.log asset.dst
console.log asset.md5
console.log asset.url
console.log asset.data
console.log asset.tag
asset.wrap()
# Wrap Single Asset - Wrap on Construction
asset = new wrap.Snockets {
src: "#{__dirname}/test.coffee"
dst: '/js/app.js'
}, (asset) ->
console.log asset.src
console.log asset.dst
console.log asset.md5
console.log asset.url
console.log asset.data
console.log asset.tag
# Wrap Single Asset with Zappa
@get '/js/app.js': ->
new wrap.Snockets {
url: '/js/app.js'
src: "#{__dirname}/path/to/app.coffee"
}, (asset) =>
@response.setHeader 'Content-Type', 'text/javascript'
@response.write asset.data
FAQs
Asset management framework for nodejs
The npm package asset-wrap receives a total of 149 weekly downloads. As such, asset-wrap popularity was classified as not popular.
We found that asset-wrap demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.