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

@rsbuild/shared

Package Overview
Dependencies
Maintainers
3
Versions
193
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rsbuild/shared - npm Package Compare versions

Comparing version 0.4.0 to 0.4.1

5

dist/types/config/performance.d.ts

@@ -39,7 +39,2 @@ import type { Configuration } from '@rspack/core';

/**
* Specifies whether to modularize the import of [lodash](https://npmjs.com/package/lodash)
* and remove unused lodash modules to reduce the code size of lodash.
*/
transformLodash?: boolean;
/**
* Controls the Rsbuild's caching behavior during the build process.

@@ -46,0 +41,0 @@ */

62

dist/types/thirdParty.d.ts

@@ -66,14 +66,76 @@ import type { Options as SassOptions, LegacyOptions as LegacySassOptions } from '../../compiled/sass';

export interface CSSLoaderOptions {
/**
* Allow to enable/disables handling the CSS functions url and image-set.
* If set to false, css-loader will not parse any paths specified in url or image-set
*
* @default true
*/
url?: boolean | ((url: string, resourcePath: string) => boolean);
/**
* Allows to enables/disables @import at-rules handling.
*
* @default true
*/
import?: boolean | ((url: string, media: string, resourcePath: string) => boolean);
/**
* Allows to enable/disable CSS Modules or ICSS and setup configuration:
*/
modules?: boolean | string | CSSModulesOptions;
/**
* By default generation of source maps depends on the devtool option.
*/
sourceMap?: boolean;
/**
* Allows to enables/disables or setups number of loaders applied before CSS loader for @import at-rules,
* CSS modules and ICSS imports, i.e. @import/composes/@value value from './values.css'/etc.
*
* @default 0
*/
importLoaders?: number;
/**
* By default, css-loader generates JS modules that use the ES modules syntax.
* There are some cases in which using ES modules is beneficial, like in the case of module concatenation and tree shaking.
*
* @default true
*/
esModule?: boolean;
/**
* Allows exporting styles as array with modules, string or constructable stylesheet (i.e. CSSStyleSheet)
*
* @default 'array'
*/
exportType?: 'array' | 'string' | 'css-style-sheet';
}
export type StyleLoaderInjectType = 'styleTag' | 'singletonStyleTag' | 'lazyStyleTag' | 'lazySingletonStyleTag' | 'linkTag';
export interface StyleLoaderOptions {
/**
* By default, style-loader generates JS modules that use the ES modules syntax.
* There are some cases in which using ES modules is beneficial, like in the case of module concatenation and tree shaking.
*
* @default true
*/
esModule?: boolean;
/**
* Allows to setup how styles will be injected into the DOM.
*
* @default 'styleTag'
*/
injectType?: StyleLoaderInjectType;
/**
* If defined, the style-loader will attach given attributes with their values on <style> / <link> element.
* @default {}
*/
attributes?: Record<string, string>;
/**
* By default, the style-loader appends <style>/<link> elements to the end of the style target, which is the <head> tag of the page unless specified by insert.
* This will cause CSS created by the loader to take priority over CSS already present in the target.
* You can use other values if the standard behavior is not suitable for you, but we do not recommend doing this.
*
* @default 'head'
*/
insert?: string | ((element: HTMLElement) => void);
/**
* Allows to setup absolute path to custom function that allows to override default behavior styleTagTransform.
*/
styleTagTransform?: string | ((css: string, styleElement: HTMLStyleElement, options: Record<string, any>) => void);
}

2

dist/utils.d.ts

@@ -31,3 +31,3 @@ /// <reference types="node" />

export declare const awaitableGetter: <T>(promises: Promise<T>[]) => AwaitableGetter<T>;
export declare const getJsSourceMap: (config: NormalizedConfig) => false | "cheap-module-source-map" | "cheap-source-map" | "source-map" | "inline-cheap-source-map" | "inline-cheap-module-source-map" | "inline-source-map" | "inline-nosources-cheap-module-source-map" | "inline-nosources-source-map" | "nosources-cheap-source-map" | "nosources-cheap-module-source-map" | "nosources-source-map" | "hidden-nosources-cheap-source-map" | "hidden-nosources-cheap-module-source-map" | "hidden-nosources-source-map" | "hidden-cheap-source-map" | "hidden-cheap-module-source-map" | "hidden-source-map" | "eval-cheap-source-map" | "eval-cheap-module-source-map" | "eval-source-map" | "eval-nosources-cheap-source-map" | "eval-nosources-cheap-module-source-map" | "eval-nosources-source-map";
export declare const getJsSourceMap: (config: NormalizedConfig) => false | "cheap-module-source-map" | "eval" | "cheap-source-map" | "source-map" | "inline-cheap-source-map" | "inline-cheap-module-source-map" | "inline-source-map" | "inline-nosources-cheap-source-map" | "inline-nosources-cheap-module-source-map" | "inline-nosources-source-map" | "nosources-cheap-source-map" | "nosources-cheap-module-source-map" | "nosources-source-map" | "hidden-nosources-cheap-source-map" | "hidden-nosources-cheap-module-source-map" | "hidden-nosources-source-map" | "hidden-cheap-source-map" | "hidden-cheap-module-source-map" | "hidden-source-map" | "eval-cheap-source-map" | "eval-cheap-module-source-map" | "eval-source-map" | "eval-nosources-cheap-source-map" | "eval-nosources-cheap-module-source-map" | "eval-nosources-source-map";
export declare const getSharedPkgCompiledPath: (packageName: SharedCompiledPkgNames) => string;

@@ -34,0 +34,0 @@ export declare const isURL: (str: string) => boolean;

{
"name": "@rsbuild/shared",
"version": "0.4.0",
"version": "0.4.1",
"description": "The internal shared modules and dependencies of Rsbuild.",

@@ -126,3 +126,3 @@ "homepage": "https://rsbuild.dev",

"dependencies": {
"@rspack/core": "0.5.3",
"@rspack/core": "0.5.4",
"caniuse-lite": "^1.0.30001583",

@@ -129,0 +129,0 @@ "postcss": "^8.4.33"

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