Twing extensions

You can add your own twing extensions to wingsuit.

Wingsuit 2

  1. Create a file wingsuit.twing.environment.js
  2. Add twing functions or filters to this environment. Example:
const environment = require('./dist/environment');
/**
const TwingFunction = require('twing').TwingFunction;
const functionName = new TwingFunction('functionName', function () {
return new Promise((resolve) => {
resolve('demo');
});
});
environment.addFunction(functionName);
**/
module.exports = environment;

Click here for more infos about twing extensions.

Wingsuit 1

Here a sample to add a new function apps/storybook/preview.js:

const renderImpl = new TwingRenderer();
const twingEnvironment = renderImpl.getEnvironment();
let function = new TwingFunction('function_name', function () {
    // ...
});
twingEnvironment.addFunction(function);

Click here for more infos about twing extensions.

Read further
Configure your app?
Check the parameters under the "App details" section and extend your wingsuit.config.js