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

asset-pipe-client

Package Overview
Dependencies
Maintainers
2
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

asset-pipe-client - npm Package Compare versions

Comparing version 1.0.0-alpha.2 to 1.0.0-beta.1

23

lib/main.js
'use strict';
const url = require('url');
const fs = require('fs');

@@ -35,8 +36,10 @@ const JSONStream = require('JSONStream');

/**
* Upload asset feed to asset server
*/
uploadFeed () {
return new Promise((resolve, reject) => {
const writer = new Writer(this.files, this.options);
const writer = new Writer(this.files, this.options, false, true);

@@ -61,3 +64,9 @@ this.transforms.forEach((entry) => {

}
resolve(body);
if (response.statusCode === 200) {
return resolve(body);
}
if (response.statusCode === 400) {
return reject(new Error(body.message));
}
reject(new Error(`Asset build server responded with unknown error. Http status ${response.statusCode}`));
}));

@@ -67,5 +76,7 @@ });

/**
* Make a bundle out of asset feeds on the asset server
*/
createRemoteBundle (sources) {

@@ -81,3 +92,9 @@ return new Promise((resolve, reject) => {

}
resolve(body);
if (response.statusCode === 200) {
return resolve(body);
}
if (response.statusCode === 400) {
return reject(new Error(body.message));
}
reject(new Error(`Asset build server responded with unknown error. Http status ${response.statusCode}`));
});

@@ -84,0 +101,0 @@ });

13

package.json
{
"name": "asset-pipe-client",
"version": "1.0.0-alpha.2",
"version": "1.0.0-beta.1",
"author": {

@@ -28,5 +28,2 @@ "name": "Trygve Lie",

],
"engines": {
"node": "6.x"
},
"bugs": {

@@ -38,3 +35,3 @@ "url": "https://github.com/asset-pipe/asset-pipe-cli/issues"

"JSONStream": "^1.3.0",
"asset-pipe-js-writer": "^1.0.0-alpha.7",
"asset-pipe-js-writer": "1.0.0-beta.3",
"commander": "2.9.0",

@@ -44,3 +41,5 @@ "request": "^2.79.0"

"devDependencies": {
"ava": "^0.18.1",
"asset-pipe-test-es5a": "^1.0.0",
"asset-pipe-test-es5b": "^1.0.0",
"tap": "10.3.1",
"eslint": "^3.15.0",

@@ -51,4 +50,4 @@ "eslint-config-finn": "^1.0.1"

"lint": "eslint .",
"test": "ava lib/*.test.js"
"test": "tap test/*.js"
}
}
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