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

@ms-cloudpack/bundler-plugin-ori

Package Overview
Dependencies
Maintainers
2
Versions
277
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ms-cloudpack/bundler-plugin-ori - npm Package Compare versions

Comparing version 0.12.1 to 0.12.2

9

lib/getOriOptions.d.ts
import type { BundleOptions } from '@ms-cloudpack/bundler-types';
import type { BuildOptions as OriBuildOptions } from 'oribuild';
/**
* The intended use of `absWorkingDir` in esbuild is to resolve relative paths from options.
* However, ori also uses `absWorkingDir` as the virtual FS root for module resolution in plugins.
* This means if `inputPath` is an individual package in a monorepo, ori won't be able to resolve
* scss `@import`s from other packages (which are often in `node_modules` at the git root).
* As a workaround, we use the git root (if available) as `absWorkingDir` and adjust all other paths.
* https://github.com/microsoft/cloudpack/issues/1174
*/
export declare function getAbsWorkingDir(inputPath: string): string;
export declare function getOriOptions(options: BundleOptions): OriBuildOptions;
//# sourceMappingURL=getOriOptions.d.ts.map

2

lib/getOriOptions.js

@@ -62,3 +62,3 @@ import { builtinModules } from 'module';

*/
function getAbsWorkingDir(inputPath) {
export function getAbsWorkingDir(inputPath) {
try {

@@ -65,0 +65,0 @@ return findGitRoot(inputPath);

import { slash } from '@ms-cloudpack/path-string-parsing';
import path from 'path';
import { getAbsWorkingDir } from './getOriOptions.js';
export function normalizeOutput(params) {

@@ -57,3 +58,3 @@ const { options, input, output } = params;

location: {
file: slash(path.resolve(inputPath, location.file)),
file: slash(path.resolve(getAbsWorkingDir(inputPath), location.file)),
line: location.line,

@@ -60,0 +61,0 @@ column: location.column,

{
"name": "@ms-cloudpack/bundler-plugin-ori",
"version": "0.12.1",
"version": "0.12.2",
"description": "An abstraction to bundle source code using ori.",

@@ -5,0 +5,0 @@ "license": "MIT",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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