How to use the polyfill-library/lib/sources.getPolyfillMeta function in polyfill-library

To help you get started, we’ve selected a few polyfill-library 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 Financial-Times / polyfill-service / packages / polyfill-service / service / routes / docs.js View on Github external
.map(feat => {
					const polyfill = sources.getPolyfillMeta(feat);
					const fdata = {
						feature: feat,
						slug: feat.replace(/[^\w]/g, '_'),
						size: polyfill.size,
						isDefault: (polyfill.aliases && polyfill.aliases.indexOf('default') !== -1),
						hasTests: polyfill.hasTests,
						docs: polyfill.docs,
						baseDir: polyfill.baseDir,
						spec: polyfill.spec,
						notes: polyfill.notes ? polyfill.notes.map(function (n) { return marky(n); }) : [],
						license: polyfill.license,
						licenseIsUrl: polyfill.license && polyfill.license.length > 5
					};

					browsers.forEach(browser => {
						if (compatdata[feat][browser]) {