Fix compilation errors
This commit is contained in:
parent
b3600dce85
commit
8e1e5e16f5
1 changed files with 8 additions and 7 deletions
|
@ -10,12 +10,11 @@ import Pattern from './pattern/src/index.js'
|
||||||
* Without it, we can't import the pattern as a local file
|
* Without it, we can't import the pattern as a local file
|
||||||
* since create-react-app does not allow imports outside ./src
|
* since create-react-app does not allow imports outside ./src
|
||||||
* If it's imported as a dependency, webpack will cache the
|
* If it's imported as a dependency, webpack will cache the
|
||||||
* build and there will be no hot-relaoding of changes
|
* build and there will be no hot-reloading of changes
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
const App = (props) => {
|
const App = (props) => {
|
||||||
// You can use this to add transations
|
// You can use this to add translations
|
||||||
/*
|
/*
|
||||||
let translations = {
|
let translations = {
|
||||||
JSON: 'JSON',
|
JSON: 'JSON',
|
||||||
|
@ -26,17 +25,19 @@ const App = (props) => {
|
||||||
// Adds support for loading an external pattern configuration
|
// Adds support for loading an external pattern configuration
|
||||||
let recreate = false
|
let recreate = false
|
||||||
if (window) recreate = window.location.pathname.substr(1).split('/')
|
if (window) recreate = window.location.pathname.substr(1).split('/')
|
||||||
if (recreate.length === 3 && recreate[0] === 'recreate')
|
if (recreate.length === 3 && recreate[0] === 'recreate') {
|
||||||
recreate = { from: recreate[1], id: recreate[2] }
|
recreate = { from: recreate[1], id: recreate[2] }
|
||||||
else recreate = false
|
} else {
|
||||||
|
recreate = false
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Workbench
|
<Workbench
|
||||||
freesewing={freesewing}
|
freesewing={freesewing}
|
||||||
Pattern={Pattern}
|
Pattern={Pattern}
|
||||||
userLanguage="{{language}}"
|
userLanguage="en"
|
||||||
recreate={recreate}
|
recreate={recreate}
|
||||||
//translations={translations}
|
// translations={translations}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue