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

koatty_core

Package Overview
Dependencies
Maintainers
0
Versions
112
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

koatty_core - npm Package Compare versions

Comparing version 1.10.0-6 to 1.10.0-7

babel.config.js

82

.rollup.config.js

@@ -1,63 +0,27 @@

/*
* @Description:
* @Usage:
* @Author: richen
* @Date: 2021-12-17 10:20:44
* @LastEditTime: 2024-11-01 10:09:45
*/
import json from "@rollup/plugin-json";
import json from '@rollup/plugin-json';
import del from 'rollup-plugin-delete';
import typescript from 'rollup-plugin-typescript2';
// import babel from '@rollup/plugin-babel';
export default [
export default {
input: './src/index.ts',
output: [
{
input: './src/index.ts',
output: [{
format: 'cjs',
file: './dist/index.js',
banner: require('./scripts/copyright')
}],
plugins: [
// babel({
// babelHelpers: "runtime",
// configFile: './babel.config.js',
// exclude: 'node_modules/**',
// }),
json(),
typescript({
tsconfigOverride: {
compilerOptions: {
declaration: false,
declarationMap: false,
module: "ESNext"
}
}
})
]
format: 'cjs',
file: './dist/index.js',
banner: require('./scripts/copyright'),
},
{
input: './src/index.ts',
output: [{
format: 'es',
file: './dist/index.mjs',
banner: require('./scripts/copyright')
}],
plugins: [
// babel({
// babelHelpers: "runtime",
// configFile: './babel.config.js',
// exclude: 'node_modules/**',
// }),
json(),
typescript({
tsconfigOverride: {
compilerOptions: {
declaration: false,
declarationMap: false,
module: "ESNext"
}
}
})
]
}
]
],
plugins: [
del({ targets: 'dist/*' }), // 在构建之前清理 dist 目录
json(),
typescript({
tsconfigOverride: {
compilerOptions: {
declaration: false,
declarationMap: false,
"module": "ESNext", // 输出 ES Module
},
},
}),
],
};

@@ -5,2 +5,4 @@ # Changelog

## [1.10.0-7](https://github.com/koatty/koatty_core/compare/v1.10.0-6...v1.10.0-7) (2024-11-01)
## [1.10.0-6](https://github.com/koatty/koatty_core/compare/v1.10.0-5...v1.10.0-6) (2024-11-01)

@@ -7,0 +9,0 @@

/*!
* @Author: richen
* @Date: 2024-11-01 10:13:23
* @Date: 2024-11-01 17:30:37
* @License: BSD (3-Clause)

@@ -5,0 +5,0 @@ * @Copyright (c) - <richenlin(at)gmail.com>

/*!
* @Author: richen
* @Date: 2024-11-01 10:13:02
* @Date: 2024-11-01 17:30:20
* @License: BSD (3-Clause)

@@ -31,3 +31,3 @@ * @Copyright (c) - <richenlin(at)gmail.com>

class KoattyMetadata {
internalRepo = new Map();
_internalRepo = new Map();
/**

@@ -37,3 +37,3 @@ * Set the given value for the given key

set(key, value) {
this.internalRepo.set(key, [value]);
this._internalRepo.set(key, [value]);
}

@@ -45,5 +45,5 @@ /**

add(key, value) {
const existingValue = this.internalRepo.get(key);
const existingValue = this._internalRepo.get(key);
if (existingValue === undefined) {
this.internalRepo.set(key, [value]);
this._internalRepo.set(key, [value]);
}

@@ -59,3 +59,3 @@ else {

remove(key) {
this.internalRepo.delete(key);
this._internalRepo.delete(key);
}

@@ -68,3 +68,3 @@ /**

get(key) {
let existingValue = this.internalRepo.get(key);
let existingValue = this._internalRepo.get(key);
existingValue = existingValue || [];

@@ -80,3 +80,3 @@ return existingValue;

const result = {};
this.internalRepo.forEach((values, key) => {
this._internalRepo.forEach((values, key) => {
if (values.length > 0) {

@@ -95,4 +95,4 @@ const v = values[0];

const newMetadata = new KoattyMetadata();
const newInternalRepr = newMetadata.internalRepo;
this.internalRepo.forEach((value, key) => {
const newInternalRepr = newMetadata._internalRepo;
this._internalRepo.forEach((value, key) => {
const clonedValue = value.map((v) => {

@@ -118,5 +118,5 @@ if (v instanceof Buffer) {

merge(other) {
other.internalRepo.forEach((values, key) => {
const mergedValue = (this.internalRepo.get(key) || []).concat(values);
this.internalRepo.set(key, mergedValue);
other._internalRepo.forEach((values, key) => {
const mergedValue = (this._internalRepo.get(key) || []).concat(values);
this._internalRepo.set(key, mergedValue);
});

@@ -133,3 +133,3 @@ }

const values = obj[key];
metadata.internalRepo.set(key, values);
metadata._internalRepo.set(key, values);
}

@@ -145,3 +145,3 @@ }

const result = {};
for (const [key, values] of this.internalRepo.entries()) {
for (const [key, values] of this._internalRepo.entries()) {
result[key] = values;

@@ -148,0 +148,0 @@ }

{
"name": "koatty_core",
"version": "1.10.0-6",
"version": "1.10.0-7",
"description": "Koatty framework core",

@@ -8,5 +8,5 @@ "scripts": {

"build:cp": "node scripts/postBuild && copyfiles package.json LICENSE README.md dist/",
"build:js": "del-cli --force dist && npx rollup --bundleConfigAsCjs -c .rollup.config.js",
"build:doc": "del-cli --force docs/api && npx api-documenter markdown --input temp --output docs/api",
"build:dts": "del-cli --force temp && npx tsc && npx api-extractor run --local --verbose",
"build:js": "npx rollup --bundleConfigAsCjs -c .rollup.config.js",
"build:doc": "npx api-documenter markdown --input temp --output docs/api",
"build:dts": "npx tsc && npx api-extractor run --local --verbose",
"eslint": "eslint --ext .ts,.js ./",

@@ -25,6 +25,2 @@ "lock": "npm i --package-lock-only",

"main": "./dist/index.js",
"exports": {
"require": "./dist/index.js",
"import": "./dist/index.mjs"
},
"repository": {

@@ -58,3 +54,3 @@ "type": "git",

"del-cli": "^6.x.x",
"eslint": "^8.57.x",
"eslint": "^8.x.x",
"eslint-plugin-jest": "^28.x.x",

@@ -65,3 +61,4 @@ "husky": "^4.x.x",

"reflect-metadata": "^0.x.x",
"rollup": "^4.24.3",
"rollup": "^4.x.x",
"rollup-plugin-delete": "^2.x.x",
"rollup-plugin-typescript2": "^0.x.x",

@@ -72,3 +69,3 @@ "standard-version": "^9.x.x",

"tslib": "^2.x.x",
"typescript": "^5.x.x"
"typescript": "^4.x.x"
},

@@ -75,0 +72,0 @@ "dependencies": {

{
"name": "koatty_core",
"version": "1.10.0-6",
"version": "1.10.0-7",
"description": "Koatty framework core",

@@ -8,5 +8,5 @@ "scripts": {

"build:cp": "node scripts/postBuild && copyfiles package.json LICENSE README.md dist/",
"build:js": "del-cli --force dist && npx rollup --bundleConfigAsCjs -c .rollup.config.js",
"build:doc": "del-cli --force docs/api && npx api-documenter markdown --input temp --output docs/api",
"build:dts": "del-cli --force temp && npx tsc && npx api-extractor run --local --verbose",
"build:js": "npx rollup --bundleConfigAsCjs -c .rollup.config.js",
"build:doc": "npx api-documenter markdown --input temp --output docs/api",
"build:dts": "npx tsc && npx api-extractor run --local --verbose",
"eslint": "eslint --ext .ts,.js ./",

@@ -25,6 +25,2 @@ "lock": "npm i --package-lock-only",

"main": "./dist/index.js",
"exports": {
"require": "./dist/index.js",
"import": "./dist/index.mjs"
},
"repository": {

@@ -58,3 +54,3 @@ "type": "git",

"del-cli": "^6.x.x",
"eslint": "^8.57.x",
"eslint": "^8.x.x",
"eslint-plugin-jest": "^28.x.x",

@@ -65,3 +61,4 @@ "husky": "^4.x.x",

"reflect-metadata": "^0.x.x",
"rollup": "^4.24.3",
"rollup": "^4.x.x",
"rollup-plugin-delete": "^2.x.x",
"rollup-plugin-typescript2": "^0.x.x",

@@ -72,3 +69,3 @@ "standard-version": "^9.x.x",

"tslib": "^2.x.x",
"typescript": "^5.x.x"
"typescript": "^4.x.x"
},

@@ -75,0 +72,0 @@ "dependencies": {

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