New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More →

@spin-io/sdk-app-compiler

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@spin-io/sdk-app-compiler - npm Package Compare versions

Comparing version

to
0.0.5

@@ -62,6 +62,8 @@ 'use strict';

source = _ref.source,
additionalScripts = _ref.additionalScripts;
_ref$additionalScript = _ref.additionalScripts,
additionalScripts = _ref$additionalScript === undefined ? [] : _ref$additionalScript;
_classCallCheck(this, AppCompiler);
console.log(1, additionalScripts);
this.name = name;

@@ -154,6 +156,5 @@ this.props = props;

externals = this.externals,
_additionalScripts = this.additionalScripts,
additionalScripts = _additionalScripts === undefined ? [] : _additionalScripts;
additionalScripts = this.additionalScripts;
console.log(2, additionalScripts);
return '\n <!doctype html>\n <html>\n <head>\n <meta charset="utf-8" />\n <meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1">\n <title>' + (debug ? '[DEBUG] ' : '') + name + '</title>\n <style>\n html { height: 100%; font-size: 16px; }\n body { height: 100%; margin: 0; }\n #root { height: 100%; }\n </style>\n <style>\n ' + (css || '') + '\n </style>\n </head>\n <body>\n <div id="root">' + (html || '') + '</div>\n ' + Object.keys(externals).map(function (key) {

@@ -160,0 +161,0 @@ return '<script src="' + externals[key].client(debug) + '"></script>';

{
"name": "@spin-io/sdk-app-compiler",
"version": "0.0.4",
"version": "0.0.5",
"description": "SPIN app compiler",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -13,3 +13,4 @@ import webpack from 'webpack'

export default class AppCompiler {
constructor({ name, props, source, additionalScripts }) {
constructor({ name, props, source, additionalScripts = [] }) {
console.log(1, additionalScripts)
this.name = name

@@ -76,4 +77,4 @@ this.props = props

getTemplate(css, html, debug) {
const { name, externals, additionalScripts = [] } = this
const { name, externals, additionalScripts } = this
console.log(2, additionalScripts)
return `

@@ -80,0 +81,0 @@ <!doctype html>