🚨 Shai-Hulud Strikes Again:834 Packages Compromised.Technical Analysis →
Socket
Book a DemoInstallSign in
Socket

postcss-global-data

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

postcss-global-data

PostCSS plugin to define global data that will be injected into PostCSS for use in other plugins.

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

postcss-global-data

npm version npm downloads bundle size install size codecov license

JSDocs

Forked from @csstools/postcss-global-data@3.0.0, motivated by this issue

Changes:

  • can also pass a object to the files element to control the behavior of the plugin
export interface FileConfig {
  file: string
  /**
   * Whether to remove the inject CSS after processing.
   * @default true to respect original plugin `@csstools/postcss-global-data` behavior
   */
  remove?: boolean
  /**
   * Position to insert the CSS.
   * @default 'append' to respect original plugin `@csstools/postcss-global-data` behavior
   */
  position?: 'append' | 'prepend'
}

Installation

# ✨ Auto-detect
npx nypm install postcss-global-data

# npm
npm install postcss-global-data

# yarn
yarn add postcss-global-data

# pnpm
pnpm install postcss-global-data

# bun
bun install postcss-global-data

# deno
deno install postcss-global-data

Basic Usage

postcssGlobalData({
  files: [
    'path/to/file.css',
    // now you can also pass an object to control the behavior
    // of the plugin for each file
    {
      file: 'path/to/file.css',
      remove: false,
      position: 'prepend',
    }
  ],
})

Contribution

Local development
  • Clone this repository
  • Install the latest LTS version of Node.js
  • Enable Corepack using corepack enable
  • Install dependencies using pnpm install
  • Run tests using pnpm dev or pnpm test

Sponsors

License

Published under the MIT license. Made by @byronogis and community đź’›

🤖 auto updated with automd (last updated: Wed Aug 13 2025)

Keywords

css injection

FAQs

Package last updated on 14 Aug 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts