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

@madgex/design-system

Package Overview
Dependencies
Maintainers
11
Versions
350
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@madgex/design-system - npm Package Compare versions

Comparing version 1.3.1 to 1.3.2

2

package.json
{
"name": "@madgex/design-system",
"version": "1.3.1",
"version": "1.3.2",
"scripts": {

@@ -5,0 +5,0 @@ "clean": "rimraf dist public tokens/build",

@@ -28,4 +28,56 @@ # Madgex Design System

## Working with [hapi.js](https://hapijs.com/), [vision](https://github.com/hapijs/vision) and [Nunjucks](https://mozilla.github.io/nunjucks/)
If you're wanting to use the Madgex DS components from a hapi.js+vision+Nunjucks setup you'll need to include the Madgex DS in the Nunjucks pathing:
```(js)
engines: {
njk: {
compile: (src, options) => {
const template = Nunjucks.compile(src, options.environment);
return (context) => {
return template.render(context);
};
},
prepare: (options, next) => {
options.compileOptions.environment = Nunjucks.configure(
[
Path.join(options.path),
'node_modules/@madgex/design-system/',
'node_modules/@madgex/design-system/src/',
'node_modules/@madgex/design-system/src/components/',
],
{ watch: false }
);
return next();
},
},
},
```
Then you should be able to use components as such:
```(nunjucks)
{% extends "template.njk" %} {# a base template is available in the DS #}
{% from "button/_macro.njk" import Button %} {# load the DS button component #}
{% block content %}
<p>My new project homepage</p>
{# Use the Madgex DS button! #}
{{
Button({
text: 'Click me!'
})
}}
{% endblock %}
```
Note you'll need the scss for the component styles.
## Releases
With every commit to `master` the build server attempts to create a new version using [semantic-release](https://semantic-release.gitbook.io/semantic-release/) and deploys to [npm](https://npmjs.org) as [@madgex/design-system](https://www.npmjs.com/package/@madgex/design-system).
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