Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@essex/babel-config

Package Overview
Dependencies
Maintainers
0
Versions
65
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@essex/babel-config - npm Package Compare versions

Comparing version 21.0.1 to 21.0.2

18

lib/createBabelConfig.js
/*!
* Copyright (c) Microsoft. All rights reserved.
* Licensed under the MIT license. See LICENSE file in the project.
*/ /* eslint-disable @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-explicit-any */ "use strict";
*/ "use strict";
Object.defineProperty(exports, "__esModule", {

@@ -15,9 +15,9 @@ value: true

const resolve = require.resolve;
function createBabelConfig({ modules, targets, corejs = 3, useBuiltIns = "usage", presets = [], plugins = [] }) {
function createBabelConfig({ modules, targets, corejs = 3, useBuiltIns = 'usage', presets = [], plugins = [] }) {
return {
presets: [
[
resolve("@babel/preset-env"),
resolve('@babel/preset-env'),
{
modules: modules === "cjs" ? "cjs" : false,
modules: modules === 'cjs' ? 'cjs' : false,
targets,

@@ -31,7 +31,7 @@ useBuiltIns,

plugins: [
resolve("babel-plugin-transform-typescript-metadata"),
resolve("@babel/plugin-proposal-class-properties"),
resolve("@babel/plugin-proposal-object-rest-spread"),
resolve("@babel/plugin-proposal-optional-chaining"),
resolve("@babel/plugin-proposal-nullish-coalescing-operator"),
resolve('babel-plugin-transform-typescript-metadata'),
resolve('@babel/plugin-proposal-class-properties'),
resolve('@babel/plugin-proposal-object-rest-spread'),
resolve('@babel/plugin-proposal-optional-chaining'),
resolve('@babel/plugin-proposal-nullish-coalescing-operator'),
...plugins

@@ -38,0 +38,0 @@ ]

@@ -24,7 +24,7 @@ /*!

const DEFAULT_ESSEX_BROWSERSLIST = [
">0.5%",
"not IE 11",
"not dead"
'>0.5%',
'not IE 11',
'not dead'
];
//# sourceMappingURL=getBrowsersList.js.map
/*!
* Copyright (c) Microsoft. All rights reserved.
* Licensed under the MIT license. See LICENSE file in the project.
*/ /* eslint-disable @typescript-eslint/no-var-requires */ "use strict";
*/ "use strict";
Object.defineProperty(exports, "__esModule", {

@@ -44,7 +44,7 @@ value: true

const cwd = process.cwd();
const packageJsonPath = (0, _path.join)(cwd, "package.json");
const packageJson = (0, _fs.existsSync)("package.json") ? require(packageJsonPath) : {};
const babelEsmOverride = (0, _path.join)(cwd, "babel.esm.js");
const babelCjsOverride = (0, _path.join)(cwd, "babel.cjs.js");
const useBuiltIns = packageJson.useBuiltIns || "usage";
const packageJsonPath = (0, _path.join)(cwd, 'package.json');
const packageJson = (0, _fs.existsSync)('package.json') ? require(packageJsonPath) : {};
const babelEsmOverride = (0, _path.join)(cwd, 'babel.esm.js');
const babelCjsOverride = (0, _path.join)(cwd, 'babel.cjs.js');
const useBuiltIns = packageJson.useBuiltIns || 'usage';
const corejs = packageJson.corejs || (useBuiltIns ? {

@@ -61,3 +61,3 @@ version: 3,

return (0, _createBabelConfig.createBabelConfig)({
modules: "cjs",
modules: 'cjs',
targets: (0, _getBrowsersList.getBrowsersList)(env, packageJson === null || packageJson === void 0 ? void 0 : packageJson.browserslist),

@@ -76,3 +76,3 @@ useBuiltIns,

return (0, _createBabelConfig.createBabelConfig)({
modules: "esm",
modules: 'esm',
targets: (0, _getBrowsersList.getBrowsersList)(env, packageJson.browserslist),

@@ -86,9 +86,9 @@ useBuiltIns,

return (0, _createBabelConfig.createBabelConfig)({
modules: "cjs",
modules: 'cjs',
targets: {
node: "current"
node: 'current'
},
presets: [
require("@babel/preset-typescript"),
require("@babel/preset-react")
require('@babel/preset-typescript'),
require('@babel/preset-react')
],

@@ -95,0 +95,0 @@ ...spec

{
"name": "@essex/babel-config",
"version": "21.0.1",
"version": "21.0.2",
"license": "MIT",

@@ -10,3 +10,3 @@ "author": "Chris Trevino <chtrevin@microsoft.com>",

"clean": "rimraf lib",
"build": "tsc --emitDeclarationOnly && swc src -d lib",
"build": "tsc --emitDeclarationOnly && swc src -d lib --strip-leading-paths",
"release": "yarn npm publish --tolerate-republish --access public"

@@ -20,3 +20,3 @@ },

"dependencies": {
"@babel/core": "^7.22.11",
"@babel/core": "^7.24.7",
"@babel/plugin-proposal-class-properties": "^7.18.6",

@@ -26,16 +26,16 @@ "@babel/plugin-proposal-nullish-coalescing-operator": "^7.18.6",

"@babel/plugin-proposal-optional-chaining": "^7.21.0",
"@babel/preset-env": "^7.22.14",
"@babel/preset-react": "^7.22.5",
"@babel/preset-typescript": "^7.22.11",
"@babel/preset-env": "^7.24.7",
"@babel/preset-react": "^7.24.7",
"@babel/preset-typescript": "^7.24.7",
"babel-plugin-transform-typescript-metadata": "^0.3.2",
"tslib": "^2.6.2"
"tslib": "^2.6.3"
},
"devDependencies": {
"@essex/tsconfig-node18": "^3.1.0",
"@swc/cli": "^0.1.62",
"@swc/core": "1.3.85",
"@types/node": "^20.6.1",
"rimraf": "^5.0.1",
"typescript": "^5.2.2"
"@essex/tsconfig-node18": "^3.1.1",
"@swc/cli": "^0.3.14",
"@swc/core": "1.6.5",
"@types/node": "^20.14.8",
"rimraf": "^5.0.7",
"typescript": "^5.5.2"
}
}

@@ -5,3 +5,2 @@ /*!

*/
/* eslint-disable @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-explicit-any */
const resolve = require.resolve

@@ -8,0 +7,0 @@

@@ -5,3 +5,2 @@ /*!

*/
/* eslint-disable @typescript-eslint/no-var-requires */
import { existsSync } from 'fs'

@@ -8,0 +7,0 @@ import { join } from 'path'

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc