New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@tailwindcss/oxide

Package Overview
Dependencies
Maintainers
4
Versions
1194
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tailwindcss/oxide - npm Package Compare versions

Comparing version
0.0.0-insiders.d96a48e
to
0.0.0-insiders.d979daa
+68
-53
index.js

@@ -6,5 +6,2 @@ // prettier-ignore

const { createRequire } = require('node:module')
require = createRequire(__filename)
const { readFileSync } = require('node:fs')

@@ -84,4 +81,4 @@ let nativeBinding = null

const bindingPackageVersion = require('@tailwindcss/oxide-android-arm64/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -101,4 +98,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-android-arm-eabi/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -114,3 +111,20 @@ return binding

if (process.arch === 'x64') {
if (process.config?.variables?.shlib_suffix === 'dll.a' || process.config?.variables?.node_target_type === 'shared_library') {
try {
return require('./tailwindcss-oxide.win32-x64-gnu.node')
} catch (e) {
loadErrors.push(e)
}
try {
const binding = require('@tailwindcss/oxide-win32-x64-gnu')
const bindingPackageVersion = require('@tailwindcss/oxide-win32-x64-gnu/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}
return binding
} catch (e) {
loadErrors.push(e)
}
} else {
try {
return require('./tailwindcss-oxide.win32-x64-msvc.node')

@@ -123,4 +137,4 @@ } catch (e) {

const bindingPackageVersion = require('@tailwindcss/oxide-win32-x64-msvc/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -131,2 +145,3 @@ return binding

}
}
} else if (process.arch === 'ia32') {

@@ -141,4 +156,4 @@ try {

const bindingPackageVersion = require('@tailwindcss/oxide-win32-ia32-msvc/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -158,4 +173,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-win32-arm64-msvc/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -178,4 +193,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-darwin-universal/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -195,4 +210,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-darwin-x64/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -212,4 +227,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-darwin-arm64/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -233,4 +248,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-freebsd-x64/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -250,4 +265,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-freebsd-arm64/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -272,4 +287,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-x64-musl/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -289,4 +304,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-x64-gnu/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -308,4 +323,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-arm64-musl/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -325,4 +340,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-arm64-gnu/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -344,4 +359,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-arm-musleabihf/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -361,4 +376,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-arm-gnueabihf/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -380,4 +395,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-loong64-musl/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -397,4 +412,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-loong64-gnu/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -416,4 +431,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-riscv64-musl/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -433,4 +448,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-riscv64-gnu/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -451,4 +466,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-ppc64-gnu/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -468,4 +483,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-linux-s390x-gnu/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -489,4 +504,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-openharmony-arm64/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -506,4 +521,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-openharmony-x64/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -523,4 +538,4 @@ return binding

const bindingPackageVersion = require('@tailwindcss/oxide-openharmony-arm/package.json').version
if (bindingPackageVersion !== '0.0.0-insiders.d96a48e' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d96a48e but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
if (bindingPackageVersion !== '0.0.0-insiders.d979daa' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
throw new Error(`Native binding package version mismatch, expected 0.0.0-insiders.d979daa but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
}

@@ -527,0 +542,0 @@ return binding

{
"name": "@tailwindcss/oxide",
"version": "0.0.0-insiders.d96a48e",
"version": "0.0.0-insiders.d979daa",
"repository": {

@@ -35,10 +35,6 @@ "type": "git",

"license": "MIT",
"dependencies": {
"tar": "^7.5.1",
"detect-libc": "^2.0.4"
},
"devDependencies": {
"@napi-rs/cli": "^3.2.0",
"@napi-rs/wasm-runtime": "^1.0.5",
"emnapi": "1.5.0"
"@napi-rs/cli": "^3.4.1",
"@napi-rs/wasm-runtime": "^1.1.0",
"emnapi": "1.7.1"
},

@@ -50,4 +46,3 @@ "engines": {

"index.js",
"index.d.ts",
"scripts/install.js"
"index.d.ts"
],

@@ -59,14 +54,14 @@ "publishConfig": {

"optionalDependencies": {
"@tailwindcss/oxide-darwin-arm64": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-freebsd-x64": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-linux-arm-gnueabihf": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-android-arm64": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-linux-arm64-musl": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-linux-arm64-gnu": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-darwin-x64": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-linux-x64-gnu": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-linux-x64-musl": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-win32-x64-msvc": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-wasm32-wasi": "0.0.0-insiders.d96a48e",
"@tailwindcss/oxide-win32-arm64-msvc": "0.0.0-insiders.d96a48e"
"@tailwindcss/oxide-android-arm64": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-darwin-arm64": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-darwin-x64": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-freebsd-x64": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-linux-arm-gnueabihf": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-linux-arm64-musl": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-linux-arm64-gnu": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-linux-x64-musl": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-win32-arm64-msvc": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-win32-x64-msvc": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-linux-x64-gnu": "0.0.0-insiders.d979daa",
"@tailwindcss/oxide-wasm32-wasi": "0.0.0-insiders.d979daa"
},

@@ -81,5 +76,4 @@ "scripts": {

"build:debug": "napi build --platform",
"version": "napi version",
"postinstall": "node ./scripts/install.js"
"version": "napi version"
}
}
#!/usr/bin/env node
/**
* @tailwindcss/oxide postinstall script
*
* This script ensures that the correct binary for the current platform and
* architecture is downloaded and available.
*/
const fs = require('fs')
const path = require('path')
const https = require('https')
const { extract } = require('tar')
const packageJson = require('../package.json')
const detectLibc = require('detect-libc')
const version = packageJson.version
function getPlatformPackageName() {
let platform = process.platform
let arch = process.arch
let libc = ''
if (platform === 'linux') {
libc = detectLibc.isNonGlibcLinuxSync() ? 'musl' : 'gnu'
}
// Map to our package naming conventions
switch (platform) {
case 'darwin':
return arch === 'arm64' ? '@tailwindcss/oxide-darwin-arm64' : '@tailwindcss/oxide-darwin-x64'
case 'win32':
if (arch === 'arm64') return '@tailwindcss/oxide-win32-arm64-msvc'
if (arch === 'ia32') return '@tailwindcss/oxide-win32-ia32-msvc'
return '@tailwindcss/oxide-win32-x64-msvc'
case 'linux':
if (arch === 'x64') {
return libc === 'musl'
? '@tailwindcss/oxide-linux-x64-musl'
: '@tailwindcss/oxide-linux-x64-gnu'
} else if (arch === 'arm64') {
return libc === 'musl'
? '@tailwindcss/oxide-linux-arm64-musl'
: '@tailwindcss/oxide-linux-arm64-gnu'
} else if (arch === 'arm') {
return '@tailwindcss/oxide-linux-arm-gnueabihf'
}
break
case 'freebsd':
return '@tailwindcss/oxide-freebsd-x64'
case 'android':
return '@tailwindcss/oxide-android-arm64'
default:
return '@tailwindcss/oxide-wasm32-wasi'
}
}
function isPackageAvailable(packageName) {
try {
require.resolve(packageName)
return true
} catch (e) {
return false
}
}
// Extract all files from a tarball to a destination directory
async function extractTarball(tarballStream, destDir) {
if (!fs.existsSync(destDir)) {
fs.mkdirSync(destDir, { recursive: true })
}
return new Promise((resolve, reject) => {
tarballStream
.pipe(extract({ cwd: destDir, strip: 1 }))
.on('error', (err) => reject(err))
.on('end', () => resolve())
})
}
async function downloadAndExtractBinary(packageName) {
let tarballUrl = `https://registry.npmjs.org/${packageName}/-/${packageName.replace('@tailwindcss/', '')}-${version}.tgz`
console.log(`Downloading ${tarballUrl}...`)
return new Promise((resolve) => {
https
.get(tarballUrl, (response) => {
if (response.statusCode === 302 || response.statusCode === 301) {
// Handle redirects
https.get(response.headers.location, handleResponse).on('error', (err) => {
console.error('Download error:', err)
resolve()
})
return
}
handleResponse(response)
async function handleResponse(response) {
try {
if (response.statusCode !== 200) {
throw new Error(`Download failed with status code: ${response.statusCode}`)
}
await extractTarball(
response,
path.join(__dirname, '..', 'node_modules', ...packageName.split('/')),
)
console.log(`Successfully downloaded and installed ${packageName}`)
} catch (error) {
console.error('Error during extraction:', error)
resolve()
} finally {
resolve()
}
}
})
.on('error', (err) => {
console.error('Download error:', err)
resolve()
})
})
}
async function main() {
// Don't run this script in the package source
try {
if (fs.existsSync(path.join(__dirname, '..', 'build.rs'))) {
return
}
let packageName = getPlatformPackageName()
if (!packageName) return
if (isPackageAvailable(packageName)) return
await downloadAndExtractBinary(packageName)
} catch (error) {
console.error(error)
return
}
}
main()