# Install twig with npm

JS port of the Twig templating language. Version 3.0.0 via npm; verified 2026-03-26.

## Install

```sh
sudo av install npm:twig
```

Additional install commands:

### Portable and language managers

- npm (100%):

```sh
npm install -g twig
```

  Evidence: local npm package metadata

## Package facts

- **Package key:** npm:twig
- **Package manager:** npm
- **Package manager page:** <https://www.npmjs.com/package/twig>
- **Version:** 3.0.0
- **Source summary:** JS port of the Twig templating language.
- **Homepage:** <https://github.com/twigjs/twig.js>
- **Repository:** <https://github.com/twigjs/twig.js>
- **Upstream docs:** <https://github.com/twigjs/twig.js>
- **License:** BSD-2-Clause
- **Source archive:** <https://registry.npmjs.org/twig/-/twig-3.0.0.tgz>
- **Issue tracker:** <https://github.com/twigjs/twig.js/issues>
- **Published:** 2026-03-26T19:43:50.935Z
- **Last updated:** 2026-03-26T19:43:50.935Z
- **Generated:** 2026-08-04T22:13:35+00:00

## Executables

- twigjs (cli)
- twigjs (alias)

## Dependencies

- @babel/runtime
- locutus
- minimatch
- walk

## Build dependencies

- @babel/core
- @babel/plugin-transform-runtime
- @babel/preset-env
- @eslint/js
- babel-loader
- eslint
- globals
- mocha
- path-browserify
- should
- should-sinon
- sinon
- terser-webpack-plugin
- tokenizer2
- webpack
- webpack-cli

## Install behavior

- Post-install hook: not defined
- Bottle: not available

## Freshness

- Page generated: 2026-08-04
- Package-manager version: 3.0.0
- Package-manager updated: 2026-03-26
- Local data: ok
- Upstream repository: https://github.com/twigjs/twig.js
- info: No cached GitHub release or tag data was available.

## Security Notes

No matching local secret-handling manifest was found for twig. Package metadata is still published here so future coverage has a stable package URL.


## Source Database Details

- **Source Database:** npm registry
- **Dist Tags:** Latest: 3.0.0
- **Version Count:** 65
- **Maintainers:** dave-irvine, justjohn, robloach, justafish, plepe, evgenius, willrowe
- **Author:** John Roepke
- **Publisher:** robloach
- **Engines:** Node: >=22
- **Integrity:** sha512-cMfYLWAgdW15B7L5wmanmga113e4phQmo3rk5EFuUrQd99g7I3ncxgynS38P01m4ZXBDSdMYUTV1g3A66/Y56Q==
- **Shasum:** b847ba9837f79154e8b935239fadc06a4260856a
- **Unpacked Size:** 1,179,326
- **File Count:** 0
- **Created At:** 2011-10-15T22:26:22.758Z
- **Latest Published At:** 2026-03-26T19:43:50.935Z
- **Modified At:** 2026-03-26T19:43:51.078Z


## Related links

- [Web development packages](https://pkg.so/web-dev-tools/) - Matched curated package taxonomy and local package facts.
- [speedscope](https://pkg.so/npm/speedscope/) - Both packages touch the same language runtime or ecosystem. Shared terms: cli, control, developer, developer-tools, javascript.
- [ts-add-js-extension](https://pkg.so/npm/ts-add-js-extension/) - Both packages touch the same language runtime or ecosystem. Shared terms: cli, control, developer, developer-tools, javascript.
- [scp2](https://pkg.so/npm/scp2/) - Both packages touch the same language runtime or ecosystem. Shared terms: cli, control, developer, developer-tools, javascript.

## Sources

- pkg.so package database
- package-page enrichment
- package version freshness
- pkgdb category and tag curation
- package relationship graph
- cross-ecosystem install command graph
