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

@platformatic/utils

Package Overview
Dependencies
Maintainers
8
Versions
288
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@platformatic/utils - npm Package Compare versions

Comparing version 2.22.0 to 2.23.0

lib/modules.js

6

index.js

@@ -15,3 +15,3 @@ 'use strict'

const schemaComponents = require('./lib/schema')
const { createDirectory, safeRemove } = require('./lib/directory')
const { createDirectory, safeRemove, generateDashedName } = require('./lib/directory')
const { withResolvers } = require('./lib/promises')

@@ -22,2 +22,3 @@ const { DestinationWritable } = require('./lib/streams/destination-writable')

const { checkNodeVersionForServices } = require('./lib/check-node-version')
const { createRequire, loadModule } = require('./lib/modules')

@@ -43,2 +44,3 @@ module.exports.FileWatcher = FileWatcher

module.exports.safeRemove = safeRemove
module.exports.generateDashedName = generateDashedName
module.exports.withResolvers = withResolvers

@@ -50,1 +52,3 @@ module.exports.DestinationWritable = DestinationWritable

module.exports.checkNodeVersionForServices = checkNodeVersionForServices
module.exports.createRequire = createRequire
module.exports.loadModule = loadModule
'use strict'
const generateName = require('boring-name-generator')
const { existsSync } = require('node:fs')

@@ -7,2 +8,6 @@ const { rm, mkdir } = require('node:fs/promises')

function generateDashedName () {
return generateName().dashed.replace(/\s+/g, '')
}
async function createDirectory (path, empty = false) {

@@ -36,3 +41,4 @@ if (empty) {

createDirectory,
safeRemove
safeRemove,
generateDashedName
}

10

lib/streams/pino-writable.js
'use strict'
const { Writable } = require('node:stream')
const { Transform } = require('node:stream')
const { inspect } = require('node:util')
class PinoWritable extends Writable {
// PinoWritable extends from Transform to appease Yarn
// https://github.com/yarnpkg/berry/blob/8bfe2d545e986993e4450072bac8b1044e5ebed7/packages/yarnpkg-shell/sources/pipe.ts#L43-L59
class PinoWritable extends Transform {
#write

@@ -36,2 +38,6 @@ #ignoreEmpty

_read () {
throw new Error('PinoWritable cannot be read')
}
// We don't define _writev as we have to serialize messages one by one so batching wouldn't make any sense.

@@ -38,0 +44,0 @@ }

{
"name": "@platformatic/utils",
"version": "2.22.0",
"version": "2.23.0",
"description": "Platformatic Utils",

@@ -21,3 +21,5 @@ "main": "index.js",

"fastify": "^5.0.0",
"neostandard": "^0.11.1",
"neostandard": "^0.12.0",
"pino": "^9.5.0",
"pino-test": "^1.0.1",
"typescript": "^5.5.4"

@@ -29,2 +31,3 @@ },

"@watchable/unpromise": "^1.0.2",
"boring-name-generator": "^1.0.3",
"leven": "~3.1.0",

@@ -31,0 +34,0 @@ "minimatch": "^8.0.4",

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