@@ -13,11 +13,9 @@ Webpack loader for Twig templates, based on [Twing](https://www.npmjs.com/packag
## Usage
twing-loader comes with two available behaviors. Depending on your need, you can use one or the other by setting the `renderContext` option accordingly.
twing-loader is a very straightforward Webpack loader, requiring only one option - the `environment` that is used to compile the templates.
Note that to import Twig files in TypeScript sources, you need to make the compiler aware of the existence of the `*.twig` type by either referencing the type in the code...
...or by adding `<path to node_modules>/twing-loader` to the `typeRoots` entry of your TypeScript configuration, as explained [there](https://www.typescriptlang.org/tsconfig#typeRoots).