is-absolute icon indicating copy to clipboard operation
is-absolute copied to clipboard

isWindows is not a function, when webpacked

Open autotel opened this issue 6 years ago • 2 comments

This is used as dependency in "audio-loader" library. This is my context. After transpiling my code with webpack, including the "audio-loader" library, the library fails because "isWindows is not a function". The library, however ran well when not transpiled. I did a dirty patch, replacing the first lines of "./is-absolute/index.js" as:

'use strict';

var isRelative = require('is-relative');
var isWindows = require('is-windows');
if(typeof isWindows!="function") isWindows=()=>true;

I can't imagine why in the world the "isWindows" is exporting a boolean, and less why it is doing so only after webPacking it.

autotel avatar Mar 28 '19 17:03 autotel

Just ran into the same thing...

MilesMorel avatar Mar 19 '20 23:03 MilesMorel

https://github.com/jonschlinkert/is-windows has been archived in 2019.

(Relevant because xo is relying on this package via to-absolute-glob package)

Ryuno-Ki avatar Mar 07 '25 11:03 Ryuno-Ki