swc/tests/source_map.js

10 lines
281 B
JavaScript
Raw Normal View History

2020-02-16 10:51:42 +03:00
const validate = require('sourcemap-validator');
const fs = require('fs');
const jsFile = process.argv[1];
const mapFile = process.argv[2];
const jsContent = fs.readFileSync(jsFile, 'utf-8');
const mapContent = fs.readFileSync(mapFile, 'utf-8');
validate(jsContent, mapContent);