webpackHotUpdate(0,{

/***/ 72:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
eval("Object.defineProperty(__webpack_exports__, \"__esModule\", { value: true });\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(5);\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__);\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_react_dom__ = __webpack_require__(75);\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_react_dom__);\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__components_Error__ = __webpack_require__(244);\n/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__components_App__ = __webpack_require__(89);\n\n\n\n\n\nconst params = decodeURI(window.location.search.substr(1)).split('&').reduce((params, value) => {\n  const array = value.split('=');\n  params[array[0]] = array[1];\n  return params;\n}, {\n  model: 'kevlib.json',\n  script: 'kevs/main.kevs'\n});\n\nconst root = document.getElementById('root');\n\nfetch(`http://localhost:8080/app/${params.model}`).then(res => {\n  return res.json();\n}, () => {\n  throw new __WEBPACK_IMPORTED_MODULE_2__components_Error__[\"a\" /* default */](`Kevoree Browser Tester needs \"${params.model}\". Build your project with <pre><code>npm run build</code></pre> and refresh the page.`);\n}).then(model => {\n  return fetch(`http://localhost:8080/app/${params.script}`).then(res => {\n    if (res.status === 200) {\n      return res.text();\n    }\n    throw new __WEBPACK_IMPORTED_MODULE_2__components_Error__[\"a\" /* default */](`Unable to find the KevScript file at \"${params.script}\"`);\n  }, () => {\n    throw new __WEBPACK_IMPORTED_MODULE_2__components_Error__[\"a\" /* default */](`Kevoree Browser Tester needs a KevScript at \"${params.script}\". Create one and refresh the page.`);\n  }).then(script => ({ model, script }));\n}).then(params => {\n  __WEBPACK_IMPORTED_MODULE_1_react_dom___default.a.render(__WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_3__components_App__[\"a\" /* default */], params), root);\n}).catch(err => {\n  __WEBPACK_IMPORTED_MODULE_1_react_dom___default.a.render(__WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_2__components_Error__[\"a\" /* default */], { error: err }), root);\n});//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiNzIuanMiLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vYnJvd3Nlci10ZXN0ZXIvc3JjL2luZGV4LmpzP2RkNjkiXSwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IFJlYWN0IGZyb20gJ3JlYWN0JztcbmltcG9ydCBSZWFjdERPTSBmcm9tICdyZWFjdC1kb20nO1xuaW1wb3J0IEVycm9yIGZyb20gJy4vY29tcG9uZW50cy9FcnJvcic7XG5pbXBvcnQgQXBwIGZyb20gJy4vY29tcG9uZW50cy9BcHAnO1xuXG5jb25zdCBwYXJhbXMgPSBkZWNvZGVVUkkod2luZG93LmxvY2F0aW9uLnNlYXJjaC5zdWJzdHIoMSkpXG4gIC5zcGxpdCgnJicpXG4gIC5yZWR1Y2UoKHBhcmFtcywgdmFsdWUpID0+IHtcbiAgICBjb25zdCBhcnJheSA9IHZhbHVlLnNwbGl0KCc9Jyk7XG4gICAgcGFyYW1zW2FycmF5WzBdXSA9IGFycmF5WzFdO1xuICAgIHJldHVybiBwYXJhbXM7XG4gIH0sIHtcbiAgICBtb2RlbDogJ2tldmxpYi5qc29uJyxcbiAgICBzY3JpcHQ6ICdrZXZzL21haW4ua2V2cydcbiAgfSk7XG5cbmNvbnN0IHJvb3QgPSBkb2N1bWVudC5nZXRFbGVtZW50QnlJZCgncm9vdCcpO1xuXG5mZXRjaChgaHR0cDovL2xvY2FsaG9zdDo4MDgwL2FwcC8ke3BhcmFtcy5tb2RlbH1gKVxuICAudGhlbigocmVzKS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