Socket
Book a DemoInstallSign in
Socket

twig-components-example

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

twig-components-example

An example Twig Component library using Webpack.

0.0.6
latest
Source
npmnpm
Version published
Weekly downloads
6
Maintainers
1
Weekly downloads
 
Created
Source

Build Status

twig-components-example

An example Twig Component library using Webpack.

This project was originally generated using generator-twig-components-webpack.

Getting started

To run a local webserver that shows how these components can be used, run npm install && npm start.

Including components on your site

To use these components on your site, include dist/components.bundled.js on the page and any of the included component tags. For example:

<html>
  <head>
    <script src="./twig-components-example/components.bundled.js"></script>
  </head>
  <body>
    <tce-hero src="hero.jpg" text="Great intro" subtext="Better follow up" callout-text="Click me" callout-href="/submit" align="middle"></tce-hero>
  </body>
</html>

Should render the tce-hero tag.

If you prefer to manage polyfills and the Twig.js library yourself, you can include components.js.

Running the build

To execute the entire production Webpack build, run npm run build.

Running tests

Tests are written with the web-component-tester package.

Before running tests, you'll need to setup your local environment:

  • Ensure Java is available in your PATH
  • Run npm install -g bower rollup web-component-tester

After all dependencies have been installed, run npm test.

FAQs

Package last updated on 03 May 2018

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.