How to use the @podium/utils.AssetJs function in @podium/utils

To help you get started, we’ve selected a few @podium/utils 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 podium-lib / layout / lib / layout.js View on Github external
[_addJsAsset](options = {}) {
        if (!options.value) {
            const v = this[_compabillity](this.jsRoute);
            return this[_sanitize](v, options.prefix);
        }

        const args = Object.assign({}, options, {pathname: this._pathname});
        this.jsRoute.push(new AssetJs(args));

        // deprecate
        deprecateJsReturn();
        return this[_sanitize](args.value, args.prefix);
    }
github podium-lib / podlet / lib / podlet.js View on Github external
[_addJsAsset](options = {}) {
        if (!options.value) {
            const v = this[_compabillity](this.jsRoute);
            return this[_sanitize](v, options.prefix);
        }

        const args = Object.assign({}, options, {pathname: this._pathname});
        this.jsRoute.push(new AssetJs(args));

        // deprecate
        return new JsDeprecation(this[_sanitize](args.value, args.prefix));
    }

@podium/utils

Common generic utility methods shared by @podium modules.

MIT
Latest version published 13 days ago

Package Health Score

78 / 100
Full package analysis