How to use the @mapbox/expression-jamsession.formulaToExpression function in @mapbox/expression-jamsession

To help you get started, we’ve selected a few @mapbox/expression-jamsession examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github stevage / mapbox-gl-utils / index.js View on Github external
function utils(...args) {
    if (args[0] && Array.isArray(args[0]) && args[0].raw) {
        // We're being used as a tagged template
        return jamSession.formulaToExpression(args[0].raw[0]);
    } else throw 'Mapbox-gl-utils unexpectedly called as a function. Use .init(map)'
}

@mapbox/expression-jamsession

Write Mapbox GL expressions in a more familiar, handwritable, spreadsheet-like, programming-like syntax.

BSD-2-Clause
Latest version published 3 years ago

Package Health Score

54 / 100
Full package analysis

Popular @mapbox/expression-jamsession functions

Similar packages