Last active
March 18, 2018 17:37
-
-
Save default-writer/d3e703cee7544b40abdc458c1aee1d44 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
| // ==UserScript== | |
| // @name www.farfetch.com | |
| // @namespace http://tampermonkey.net/ | |
| // @version 0.1 | |
| // @description Fix for the external lavascript loading bug (Oracle Cloud Tags BlueKai) | |
| // @author You | |
| // @match https://www.farfetch.com/* | |
| // @grant none | |
| // ==/UserScript== | |
| (function() { | |
| 'use strict'; | |
| var bk_script = document.createElement ('script'); | |
| bk_script.type = "text/javascript"; | |
| bk_script.onload = function() { | |
| //I created an AMD module for the 'https://tags.bkrtx.com/js/bk-coretag.js' file, beautified, and is loaded as wrapped module definition | |
| require.config({ | |
| paths: { 'bk': 'https://node.experimentalcommunity.org/bktag' } | |
| }); | |
| require(['bk'], function(bk){ | |
| }); | |
| }; | |
| bk_script.setAttribute("data-main","scripts/main"); | |
| bk_script.src="https://cdnjs.cloudflare.com/ajax/libs/require.js/2.3.5/require.min.js"; | |
| document.getElementsByTagName('head')[0].appendChild(bk_script); | |
| /** vim: et:ts=4:sw=4:sts=4 | |
| * @license RequireJS 2.3.5 Copyright jQuery Foundation and other contributors. | |
| * Released under MIT license, https://github.com/requirejs/requirejs/blob/master/LICENSE | |
| */ | |
| })(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment