mikaeljorhult / brackets-autoprefixer

Brackets/Edge Code extension that parses CSS documents and add vendor prefixes automatically.
MIT License
191 stars 37 forks source link

Update breaks extension in Brackets 1.8 Experimental #66

Closed DroWnThePoor closed 7 years ago

DroWnThePoor commented 7 years ago

I'm on: Release 1.8 experimental build 1.8.0-17108 (alf_localization_release_1.8 3af64fae4) build timestamp: Wed Nov 09 2016 02:47:52 GMT+0000

On a Ubuntu based system and this update caused the extension to fail.

Any suggestions? This is kind of a big deal for me.

Edit: I just updated my Brackets to version 1.9 and it still fails to install. Also tried installing from URL.

mikaeljorhult commented 7 years ago

Do you see any errors in the console?

DroWnThePoor commented 7 years ago

Sorry for the late reply. I have now updated to 1.10 because of a seperate issue the console shows:

[Extension] failed to load /home/drown/.config/Brackets/extensions/user/mikaeljorhult.brackets-autoprefixer - TypeError: Object #<Object> has no method 'log2' /utils/ExtensionLoader.js:220
errback /utils/ExtensionLoader.js:220
TypeError: Object #<Object> has no method 'log2'
    at unpackSupport (file:///home/drown/.config/Brackets/extensions/user/mikaeljorhult.brackets-autoprefixer/modules/vendor/autoprefixer/Autoprefixer.js:11463:36)
    at file:///home/drown/.config/Brackets/extensions/user/mikaeljorhult.brackets-autoprefixer/modules/vendor/autoprefixer/Autoprefixer.js:11475:28
    at Array.reduce (native)
    at file:///home/drown/.config/Brackets/extensions/user/mikaeljorhult.brackets-autoprefixer/modules/vendor/autoprefixer/Autoprefixer.js:11473:60
    at Array.reduce (native)
    at unpackFeature (file:///home/drown/.config/Brackets/extensions/user/mikaeljorhult.brackets-autoprefixer/modules/vendor/autoprefixer/Autoprefixer.js:11471:44)
    at f (file:///home/drown/.config/Brackets/extensions/user/mikaeljorhult.brackets-autoprefixer/modules/vendor/autoprefixer/Autoprefixer.js:20:12)
    at Object.caniuse-lite (file:///home/drown/.config/Brackets/extensions/user/mikaeljorhult.brackets-autoprefixer/modules/vendor/autoprefixer/Autoprefixer.js:88:1)
    at s (file:///home/drown/.config/Brackets/extensions/user/mikaeljorhult.brackets-autoprefixer/modules/vendor/autoprefixer/Autoprefixer.js:1:626)
    at file:///home/drown/.config/Brackets/extensions/user/mikaeljorhult.brackets-autoprefixer/modules/vendor/autoprefixer/Autoprefixer.js:1:677 /utils/ExtensionLoader.js:224
Can't track online status, retry in 5 mins OnlineTracking.js:56
GET http://online-dnbard.rhcloud.com/tick/54f1f443646174009a090000/%3C!DOCTYPE%…tion.replace(url);%3C/script%3E%3C/head%3E%3Cbody%3E%3C/body%3E%3C/html%3E  

Anything else you'd like to see?

DroWnThePoor commented 7 years ago

So I have gotten it to work on 1.10 by copying the folder over from another computer where I hadn't updated yet, still hoping for a fix on the latest. I don't know much about .js as I'm still learning.Wish I could help troubleshoot more.

mikaeljorhult commented 7 years ago

That's weird. The stack trace indicates an error within the library itself, not the extension, and that it's caused by a missing function within the JavaScript built-in Math library.

Would you mind running the following command in your console to see if the function is indeed missing?

console.log(Math, Math.log2);
DroWnThePoor commented 7 years ago

Okay so if I did it correctly this is what it returned.

image

Also Chrome's dev view told me that I should install "React Dev Tools" extension which I did. I don't see how this could be related but I figured I'd mention it.

mikaeljorhult commented 7 years ago

I've been trying this on a Ubuntu machine today and it seems like the shell of the Linux build of Brackets is behind the macOS build. I'll do some more testing to see if I can polyfill the function that is missing.

DroWnThePoor commented 7 years ago

Thank you very much, I know Linux desktop is a niche userbase. One question, how come Firefox prefixes aren't included in this extension? When I save I get -ms- and -webkit- but no -moz or even Opera?

mikaeljorhult commented 7 years ago

Not at all, I've just falsely assumed that the Brackets shell had about the same features across the different platforms.

Which prefixes that are used is decided by your targeted browser in your settings. Make sure that the version of Firefox you which to support is in specified.

DroWnThePoor commented 7 years ago

@mikaeljorhult Wondering if there has been any change in this? I rely on your extension quite heavily as I'm not savy with other methods, so I simply avoid updating the exension altogether.

mikaeljorhult commented 7 years ago

Unfortunately no, not yet. I'm looking into running the library through Node but I've been busy with another couple of projects. Hope to find some time to explore it further during the next couple of weeks.

mikaeljorhult commented 7 years ago

@DroWnThePoor I saw that Brackets 1.11 (still pre-release) will have an updated version of the CEF and it seem to solve the issues, at least in Ubuntu.

Can you confirm this?

DroWnThePoor commented 7 years ago

@mikaeljorhult Sorry that I'm getting back to you so late, 1.11 is now stable/released on Ubuntu 16.04, I'm currently using it. I've been using an older build of your extension successfully, and haven't updated.

mikaeljorhult commented 7 years ago

No worries. The new application shell (CEF) of Brackets should work fine with the newest version of the extension. Let me know if you run into any problems.