Skip to content
This repository was archived by the owner on Sep 5, 2018. It is now read-only.

Conversation

@pcfreak30
Copy link
Contributor

@adamsilverstein
Copy link

@pcfreak30 Thanks for the pull request. Can you explain a little more how you plan to use this library?

I did test the branch and the build went fine, this is the diff vs. the master build, does that look right?

https://cl.ly/3O2T2W3Y1r2g/diff.diff

Please note the extra whitespace you removed is there as part of the WordPress JS coding standards, see https://make.wordpress.org/core/handbook/best-practices/coding-standards/javascript/

@pcfreak30
Copy link
Contributor Author

I am using this in browserify mainly in the unit test bundle. The actual application has to enqueue it due to nonce. This has required it to be more compatible with node. I never was able to get the library to install without error as it refused to install the dependencies (don't know why).My PR has the solution that worked for me.

As for white space, it may have been my ide, wasn't trying to throw that off. Not using wp standards for js.

@pcfreak30 pcfreak30 mentioned this pull request Aug 30, 2016
@adamsilverstein
Copy link

Ok, thanks for the explanation @pcfreak30, that makes sense. Thanks also for the PR. I think I'd like to include this as a build option, not in the default build. that way we have an AMD ready plugin, but don't add code for the primary use case of enqueueing from WordPress. If you have time for an updated PR with this (plus not changing whitespace), I will merge it, or I can work on this soon!

@pcfreak30
Copy link
Contributor Author

It needs to be UMD ready, not AMD as I wont be able use to AMD.

@adamsilverstein
Copy link

@pcfreak30 Sorry this didn’t make it in before we merged this code to WP core. I'm not sure this is still needed for the library when its loaded directly from WP which is what it is built for. If you feel it would be useful, can you please open a ticket on WP Trac? Otherwise, you can make a fork of the repo for your own use.

Thanks for your contribution and effort here.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

2 participants