blob: bf89a42f17e394b1b53748ebba68b4ae2a85c2ca [file] [log] [blame]
// Copyright 2013 The Emscripten Authors. All rights reserved.
// Emscripten is available under two separate licenses, the MIT license and the
// University of Illinois/NCSA Open Source License. Both these licenses can be
// found in the LICENSE file.
// Route URL GET parameters to argc+argv
if (typeof window === "object") {
Module['arguments'] = window.location.search.substr(1).trim().split('&');
// If no args were passed arguments = [''], in which case kill the single empty string.
if (!Module['arguments'][0])
Module['arguments'] = [];
}