@falsejs/falsejs 4.1.7 → 4.1.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +30 -19
  2. package/package.json +5 -2
package/index.js CHANGED
@@ -19,12 +19,20 @@
19
19
  try {
20
20
  false.valueOf()
21
21
  } catch {
22
- global.false = [].includes() // tricky way to get false
22
+ global.false = module.exports.constructor
23
+ .values(module.exports.constructor())
24
+ .includes() // tricky way to get false
23
25
  }
24
26
  try {
25
27
  true.valueOf()
26
28
  } catch {
27
- global.true = [].constructor.name.includes("Array") // tricky way to get true
29
+ global.true = module.exports.constructor
30
+ .values(module.exports.constructor())
31
+ .constructor.name.includes(
32
+ module.exports.constructor.prototype.toString.call(
33
+ module.exports.constructor.values(module.exports.constructor()),
34
+ ).split("[object ").pop().split("]")[NaN.constructor.prototype.valueOf()],
35
+ ) // tricky way to get true
28
36
  }
29
37
 
30
38
  const isComputerOnFire = require("is-computer-on-fire").isComputerOnFire // require external is-computer-on-fire package.
@@ -57,6 +65,8 @@ if (isComputerOnFire()) {
57
65
  require("user")() // something else that improves load times and performance
58
66
  require("vapor-js-npm") // vapor also makes your program faster
59
67
 
68
+ // replaceAllOf
69
+ require("str-replaceallof-es").shim()
60
70
  ;(function (factory) {
61
71
  module.exports.default = factory(jQuery) // run and export falsejs.
62
72
  })(function ($) {
@@ -65,7 +75,7 @@ if (isComputerOnFire()) {
65
75
 
66
76
  const jQuery = $ // alias for jquery
67
77
 
68
- const variableHolder = {} // a variable holder
78
+ const variableHolder = require("lodash.stubobject")() // a variable holder
69
79
 
70
80
  const GetIntrinsic = require("get-intrinsic") // cache our intrinsics
71
81
 
@@ -76,7 +86,7 @@ if (isComputerOnFire()) {
76
86
  const _ = require("lodash") // every project needs lodash
77
87
  const underscore = require("underscore") // underscore.js. the predecessor of lodash.
78
88
  const k = require("kitty") // lodash but with some mixins in it
79
- const aura = require("lolite") // the 10x utility package
89
+ const lolite = require("lolite") // the 10x utility package
80
90
  const React = require("react") // the hype framework everyone uses for some reason
81
91
  const ReactDOMServer = require("react-dom/server") // part of react
82
92
  const cheerio = require("cheerio") // cheerio!
@@ -283,7 +293,7 @@ if (isComputerOnFire()) {
283
293
  const notStrictlyEqual = not(strictlyEqual)
284
294
  var trueValue = require("true-value")() // get true with quantum fisics simulation
285
295
  var tVal = trueValue // tVal sounds cool so i put it here too
286
- var t = () => whatevTrueValue // returns true.
296
+ var t = require("@substack/is-match")() // returns true.
287
297
  const { mGenbaneko } = require("genbaneko") // i like cats
288
298
  const leftPad = require("left-pad") //every project needs leftpad.
289
299
  const rightPad = require("right-pad") //to the right, to the right.
@@ -347,9 +357,10 @@ if (isComputerOnFire()) {
347
357
 
348
358
  // A useful function to get a DHTML string.
349
359
  function getDHTMLString() {
350
- return `netscape_layer_id_${
351
- thirteenResolver() * thirteenResolver() * thirteenResolver()
352
- }`
360
+ return `netscape_layer_id_${lolite.multiply(
361
+ thirteenResolver(),
362
+ lolite.multiply(thirteenResolver(), thirteenResolver()),
363
+ )}`
353
364
  }
354
365
 
355
366
  const NumberFormatter = Intl.NumberFormat
@@ -373,12 +384,12 @@ if (isComputerOnFire()) {
373
384
  +" "
374
385
  )
375
386
  //100 whitespaces
376
- .replaceAll(" ", require("space-string"))
387
+ .replaceAllOf(" ", require("space-string"))
377
388
  const STARTING_SUCCESSOR_HELPER_STACK = zr0()
378
- const FALSE = aura.not(whatevTrueValue)
389
+ const FALSE = lolite.not(whatevTrueValue)
379
390
  const _f = constant(FALSE)
380
391
  const ERROR_THAT_WILL_NEVER_BE_SHOWN = variableHolder._lilmessage
381
- const TEN_THOUSAND = aura.multiply(numberOneHundred, numberOneHundred)
392
+ const TEN_THOUSAND = lolite.multiply(numberOneHundred, numberOneHundred)
382
393
  const LEFT_PAD_INPUT = jQuery.multiply(
383
394
  five(),
384
395
  jQuery.add(five(), jQuery.divide(five(), five())),
@@ -550,7 +561,7 @@ if (isComputerOnFire()) {
550
561
  var total = zr0()
551
562
  // let's use underscore instead of forEach
552
563
  underscore.each(nums, (num) => {
553
- total = aura.add(total, num)
564
+ total = lolite.add(total, num)
554
565
  })
555
566
  return total
556
567
  }
@@ -558,13 +569,15 @@ if (isComputerOnFire()) {
558
569
  var total = zr0()
559
570
  // this time we'll use lodash
560
571
  _.each(nums, (num) => {
561
- total = aura.subtract(total, num)
572
+ total = lolite.subtract(total, num)
562
573
  })
563
574
  return total
564
575
  }
565
576
  $.equals = (v1, v2) => {
566
577
  if (
567
- not(() => isActualNumber(v1) && logicalNot(isActualNumber(v2)))()
578
+ not(() =>
579
+ lolite.and(isActualNumber(v1), logicalNot(isActualNumber(v2))),
580
+ )()
568
581
  ) {
569
582
  immediateError(
570
583
  concatenater(
@@ -599,7 +612,7 @@ if (isComputerOnFire()) {
599
612
  }
600
613
  }
601
614
 
602
- const surpriseArray = [] // define empty array
615
+ const surpriseArray = require("lodash.stubarray")() // define empty array
603
616
  setLogFuntion(() => {
604
617
  // create an ending random number for our users eventually
605
618
  surpriseArray.push(
@@ -644,7 +657,7 @@ if (isComputerOnFire()) {
644
657
  }
645
658
 
646
659
  function predecessor(n) {
647
- return aura.add(n, aura.invert(one))
660
+ return lolite.add(n, lolite.invert(one))
648
661
  }
649
662
 
650
663
  function vValue(num) {
@@ -2551,9 +2564,7 @@ if (isComputerOnFire()) {
2551
2564
  // Calculate a hash-like value using trigonometric functions
2552
2565
  const trigValue =
2553
2566
  parseFloat(
2554
- parseFloat(
2555
- add("0.", baseConverted),
2556
- ) *
2567
+ parseFloat(add("0.", baseConverted)) *
2557
2568
  (five() + (five() / five() + five() / five())) *
2558
2569
  five() +
2559
2570
  five() / five(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@falsejs/falsejs",
3
- "version": "4.1.7",
3
+ "version": "4.1.8",
4
4
  "description": "Returns false.",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -175,9 +175,11 @@
175
175
  "lodash._noop": "^2.2.1",
176
176
  "lodash.constant": "^3.0.0",
177
177
  "lodash.noop": "^3.0.1",
178
+ "lodash.stubarray": "^4.13.0",
179
+ "lodash.stubobject": "^4.13.0",
178
180
  "logtoconsole": "^1.0.7",
179
181
  "lolcatjs": "^2.4.3",
180
- "lolite": "^1.1.15",
182
+ "lolite": "^1.1.24",
181
183
  "lua-interpreter": "^0.0.3",
182
184
  "luaparse": "^0.3.1",
183
185
  "meow.js": "^1.0.6",
@@ -233,6 +235,7 @@
233
235
  "sixteen-constant": "^1.0.0",
234
236
  "sixty-seven": "^1.0.0",
235
237
  "space-string": "^1.0.0",
238
+ "str-replaceallof-es": "^1.0.0",
236
239
  "striptags": "^3.2.0",
237
240
  "successor": "^1.0.1",
238
241
  "the-number-one": "^1.0.1",