chore: remove output-file-sync dependency (#10619)

This commit is contained in:
Huáng Jùnliàng
2019-10-31 14:51:36 -04:00
committed by Brian Ng
parent 0b0edc3e3d
commit a2b5437b01
5 changed files with 18 additions and 5 deletions

View File

@@ -1,7 +1,7 @@
const readdir = require("fs-readdir-recursive");
const helper = require("@babel/helper-fixtures");
const rimraf = require("rimraf");
const outputFileSync = require("output-file-sync");
const { sync: makeDirSync } = require("make-dir");
const child = require("child_process");
const merge = require("lodash/merge");
const path = require("path");
@@ -14,6 +14,11 @@ const fileFilter = function(x) {
return x !== ".DS_Store";
};
const outputFileSync = function(filePath, data) {
makeDirSync(path.dirname(filePath));
fs.writeFileSync(filePath, data);
};
const presetLocs = [path.join(__dirname, "../../babel-preset-react")];
const pluginLocs = [