-
-
Save remy/664147 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
var css = [ | |
'/css/default.css', | |
'/css/section.css', | |
'/css/custom.css' | |
], | |
i = 0, | |
link = document.createElement('link'); | |
link.rel = 'stylesheet', | |
head = document.getElementsByTagName('head')[0], | |
tmp; | |
for(; i < css.length; i++){ | |
tmp = link.cloneNode(); | |
tmp.href = css[i]; | |
head.appendChild(link); | |
} | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Notice the semi-colon at the end of L8, oops! Comma-first FTW! Also you're appending
link
instead oftmp
.