New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@smpx/babel-changed

Package Overview
Dependencies
Maintainers
2
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@smpx/babel-changed - npm Package Compare versions

Comparing version 0.3.0 to 0.4.0

5

index.js

@@ -112,3 +112,3 @@ const babel = require('@babel/core');

await fs.unlink(destFile).catch((err) => {
logger.warn('A file could not be removed,', destFile, err.message)
logger.warn('[babel] A file could not be removed,', destFile, err.message)
});

@@ -131,3 +131,4 @@ });

await pMap(filesToCompile, async (srcFile) => {
const destFile = `${destDir}${srcFile.substring(srcDir.length)}`;
let destFile = `${destDir}${srcFile.substring(srcDir.length)}`;
destFile = `${destFile.slice(0, destFile.length - path.extname(destFile).length)}.js`;
const result = await babel.transformFileAsync(srcFile, options);

@@ -134,0 +135,0 @@

2

package.json
{
"name": "@smpx/babel-changed",
"version": "0.3.0",
"version": "0.4.0",
"description": "Only compile changed files with babel",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -66,1 +66,11 @@ # babel-changed

```
### Extensions/Typescript support
For compiling TS/JSX files with babel, change the extensions to compile like below:
```sh
babel-changed -e ".js,.ts"
```
**NOTE**: Extension of compiled file will always be `.js`.
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