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

@callstack/reassure-danger

Package Overview
Dependencies
Maintainers
10
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@callstack/reassure-danger - npm Package Compare versions

Comparing version 0.1.1 to 1.0.0-beta

lib/typescript/dangerjs.d.ts.map

30

lib/commonjs/dangerjs.js

@@ -7,15 +7,25 @@ "use strict";

exports.dangerReassure = dangerReassure;
var fs = _interopRequireWildcard(require("fs"));
var path = _interopRequireWildcard(require("path"));
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
/**
* Declaring dangerjs API methods used in the plugin
* ---
* @function warn(message: string): void;
* - displays a warning message in Danger's output in MR after CI pipeline finishes running
* - does NOT stop the pipeline run itself
* @function markdown(message: string): void;
* - displays a markdown content in Danger's output in MR after CI pipeline finishes running
* - allows for displaying messages in markdown format
*/
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
/**
* Configuration object which can optionally be passed down to plugin's call.
* By default, it will only pass the inputFilePath parameter
*/
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
function dangerReassure() {
let config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {
inputFilePath: '.reassure/output.md'
};
function dangerReassure(config = {
inputFilePath: '.reassure/output.md'
}) {
const _warning = `

@@ -30,7 +40,5 @@ ⚠️ No output file found @ ${config.inputFilePath}

`;
try {
const perfFilePath = path.resolve(config.inputFilePath);
const perfFileContents = fs.readFileSync(perfFilePath, 'utf8');
if (config.debug) {

@@ -37,0 +45,0 @@ if (!perfFileContents) {

@@ -12,4 +12,3 @@ "use strict";

});
var _dangerjs = require("./dangerjs");
//# sourceMappingURL=index.js.map
import * as fs from 'fs';
import * as path from 'path';
/**

@@ -14,6 +15,10 @@ * Declaring dangerjs API methods used in the plugin

export function dangerReassure() {
let config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {
inputFilePath: '.reassure/output.md'
};
/**
* Configuration object which can optionally be passed down to plugin's call.
* By default, it will only pass the inputFilePath parameter
*/
export function dangerReassure(config = {
inputFilePath: '.reassure/output.md'
}) {
const _warning = `

@@ -28,7 +33,5 @@ ⚠️ No output file found @ ${config.inputFilePath}

`;
try {
const perfFilePath = path.resolve(config.inputFilePath);
const perfFileContents = fs.readFileSync(perfFilePath, 'utf8');
if (config.debug) {

@@ -35,0 +38,0 @@ if (!perfFileContents) {

@@ -7,3 +7,4 @@ /**

*/
export { dangerReassure } from './dangerjs';
//# sourceMappingURL=index.js.map

@@ -5,3 +5,3 @@ /**

*/
export declare type DangerPluginConfig = {
export type DangerPluginConfig = {
inputFilePath: string;

@@ -11,1 +11,2 @@ debug?: boolean;

export declare function dangerReassure(config?: DangerPluginConfig): void;
//# sourceMappingURL=dangerjs.d.ts.map

@@ -8,1 +8,2 @@ /**

export { dangerReassure } from './dangerjs';
//# sourceMappingURL=index.d.ts.map
{
"name": "@callstack/reassure-danger",
"version": "0.1.1",
"version": "1.0.0-beta",
"description": "Performance testing companion for React and React Native",

@@ -13,3 +13,2 @@ "main": "lib/commonjs/index",

"lib",
"!lib/typescript/examples",
"!**/__tests__",

@@ -45,3 +44,8 @@ "!**/__fixtures__",

"module",
"typescript"
[
"typescript",
{
"project": "tsconfig.build.json"
}
]
]

@@ -48,0 +52,0 @@ },

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