Giter Club home page Giter Club logo

lodashify's Introduction

#lodashify v1.0.0

Want an easy way to poke at a page with Lo-Dash [compat-dev v.1.0.0]?

Create a bookmark with this for the URL (sorry, embedding the bookmarklet didn't work):

javascript:(function(){var%20el=document.createElement(%22div%22),b=document.getElementsByTagName(%22body%22)[0],otherlib=false,msg=%22%22;el.style.position=%22fixed%22;el.style.height=%2232px%22;el.style.width=%22220px%22;el.style.marginLeft=%22-110px%22;el.style.top=%220%22;el.style.left=%2250%25%22;el.style.padding=%225px%2010px%22;el.style.zIndex=1001;el.style.fontSize=%2212px%22;el.style.color=%22%23222%22;el.style.backgroundColor=%22%23f99%22;if(typeof%20_!=%22undefined%22){msg=%22This%20page%20already%20using%20Lo-Dash%20v%22+_.VERSION;return%20showMsg()}else%20if(typeof%20_==%22function%22)otherlib=true;function%20getScript(url,success){var%20script=document.createElement(%22script%22);script.src=url;var%20head=document.getElementsByTagName(%22head%22)[0],done=false;script.onload=script.onreadystatechange=function(){if(!done%26%26(!this.readyState||this.readyState==%22loaded%22||this.readyState==%22complete%22)){done=true;success();script.onload=script.onreadystatechange=null;head.removeChild(script)}};head.appendChild(script)}getScript(%22http://cdnjs.cloudflare.com/ajax/libs/lodash.js/1.0.0/lodash.compat.js%22,function(){if(typeof%20_==%22undefined%22)msg=%22Sorry,%20but%20Lo-Dash%20wasn't%20able%20to%20load%22;else{msg=%22This%20page%20is%20now%20Lo-Dashified%20with%20v%22+_.VERSION;if(otherlib)msg+=%22%20and%20noConflict().%20Use%20lodash(),not%20_().%22}return%20showMsg()});function%20showMsg(){el.innerHTML=msg;b.appendChild(el);window.setTimeout(function(){if(typeof%20_==%22undefined%22)b.removeChild(el);else{b.removeChild(el);if(otherlib)lodash=_.noConflict()}},2500)}})();

##References

Stolen Adapted from Karl Swedberg's jQuerify bookmarklet.

Final bookmarklet generated by running things through Closure Compiler and Bookmarkleter.

##License

MIT license. If you do something cool with it, though, I'd love to hear about it.

lodashify's People

Contributors

patridge avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.