Skip to content

Instantly share code, notes, and snippets.

Avatar

Michał Gołębiowski-Owczarek mgol

View GitHub Profile
@mgol
mgol / jquery-es6-example.md
Last active Apr 20, 2020
jQuery ES6 modules example usage
View jquery-es6-example.md

jQuery source is now authored using ES6 modules. It's possible to use them directly in the browser without any build process.

To test it locally, first clone the jQuery repository:

git clone git@github.com:jquery/jquery.git

Then, write the following index.html file:

@mgol
mgol / ie11-only.md
Last active Sep 10, 2020
How to easily not serve JS and/or CSS to IE<11
View ie11-only.md

Here's how to make your site not load CSS and/or JS in IE older than 11:

<!DOCTYPE html>
<html>
    <head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=8,9,11">
        <title>Page title</title>
        <!--[if !IE]>-->
        <link rel="stylesheet" href="styles.css">
You can’t perform that action at this time.