-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
stats are loaded from script tag instead of xhr
added a script to generate a js file from csv Chrome won't load xhr to file protocols. This will allow running it locally with a script tag. run the script after the csv changes
- Loading branch information
Showing
4 changed files
with
10 additions
and
10 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# generate stats_standard_random.js from the csv file | ||
# run after changing the csv | ||
# https://www.freeformatter.com/javascript-escape.html works for this as well | ||
echo -n 'var strStats = "'>stats_standard_random.js | ||
perl -p -e "s#\\\#\\\\\\\#g;s#'#\\\'#g;s#\n#\\\n#g;s#\r##g;"'s#\"#\\"#g;s#\t#\\t#g' stats_standard_random.csv>>stats_standard_random.js | ||
echo '";'>>stats_standard_random.js |
This file contains 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.