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

elm-spa

Package Overview
Dependencies
Maintainers
1
Versions
61
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

elm-spa - npm Package Compare versions

Comparing version 6.0.8--beta to 6.0.9--beta

dist/src/templates/page.js

2

dist/package.json
{
"name": "elm-spa",
"version": "6.0.8--beta",
"version": "6.0.9--beta",
"description": "single page apps made easy",

@@ -5,0 +5,0 @@ "bin": "dist/src/index.js",

@@ -32,2 +32,4 @@ "use strict";

const pages_1 = __importDefault(require("../templates/pages"));
const page_1 = __importDefault(require("../templates/page"));
const request_1 = __importDefault(require("../templates/request"));
const model_1 = __importDefault(require("../templates/model"));

@@ -109,3 +111,6 @@ const msg_1 = __importDefault(require("../templates/msg"));

...paramFiles,
{ filepath: ['Page'], contents: page_1.default() },
{ filepath: ['Request'], contents: request_1.default() },
{ filepath: ['Gen', 'Route'], contents: routes_1.default(segments, utils_1.options(kindForPage)) },
{ filepath: ['Gen', 'Route'], contents: routes_1.default(segments, utils_1.options(kindForPage)) },
{ filepath: ['Gen', 'Pages'], contents: pages_1.default(segments, utils_1.options(kindForPage)) },

@@ -112,0 +117,0 @@ { filepath: ['Gen', 'Model'], contents: model_1.default(segments, utils_1.options(kindForPage)) },

@@ -41,2 +41,3 @@ "use strict";

defaults: [
['Auth.elm'],
['Effect.elm'],

@@ -46,4 +47,2 @@ ['Main.elm'],

[`Pages`, `${reserved.notFound}.elm`],
['Page.elm'],
['Request.elm'],
['View.elm']

@@ -50,0 +49,0 @@ ]

@@ -216,4 +216,12 @@ "use strict";

};
// Used in place of sophisticated AST parsing
const exposes = (keyword) => (elmSourceCode) => new RegExp(`module\\s(\\S)+\\sexposing(\\s)+\\([^\\)]*${keyword}[^\\)]*\\)`, 'm').test(elmSourceCode);
const exposes = (value) => (str) => {
const regex = new RegExp('^module\\s+[^\\s]+\\s+exposing\\s+\\(([^)]+)\\)');
const match = (str.match(regex) || [])[1];
if (match) {
return match.split(',').filter(a => a).map(a => a.trim()).includes(value);
}
else {
return false;
}
};
exports.exposesModel = exposes('Model');

@@ -220,0 +228,0 @@ exports.exposesMsg = exposes('Msg');

{
"name": "elm-spa",
"version": "6.0.8--beta",
"version": "6.0.9--beta",
"description": "single page apps made easy",

@@ -5,0 +5,0 @@ "bin": "dist/src/index.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