Fix some problems reported by Matthias

This commit is contained in:
jdfreder 2015-08-17 08:50:22 -07:00 committed by Jonathan Frederic
parent 6258f542dd
commit b2ae17dd09
3 changed files with 45 additions and 6 deletions

View File

@ -27,3 +27,36 @@ pip install --pre -e .
jupyter notebook
```
## Working on the frontend
The Notebook frontend depends on a wide set of libraries and package managers.
NPM is used to macro manage the frontend build process. You can build the
frontend Javascript and LESS by running
```
npm run build
```
If you need to build the Javascript alone
```
npm run build:js
```
Or LESS
```
npm run build:css
```
To build specific sub components, separate using a colon. i.e. to build only
the terminal's Javascript
```
npm run build:js:terminal
```
To clean all built output
```
npm run clean
```

View File

@ -17,14 +17,19 @@ glob(path.join(source, "**/*.js"), function(err, files) {
if (err) {
console.error('Could not read file ' + file, err);
} else {
mkdirp(path.dirname(toFile), function(err) { if (err) {console.error('Could not mkdirp ', err);} });
fs.writeFile(toFile, amdWrap(data), function(err) {
if(err) {
return console.error('Could not write file ' + toFile, err);
}
mkdirp(path.dirname(toFile), function(err) {
if (err) {
console.error('Could not mkdirp ', err);
} else {
fs.writeFile(toFile, amdWrap(data), function(err) {
if(err) {
return console.error('Could not write file ' + toFile, err);
}
});
}
});
}
});
});
}
});
});

View File

@ -35,6 +35,7 @@
"browserify": "^11.0.1",
"codemirror": "~5.5",
"concurrently": "^0.1.1",
"glob": "^5.0.14",
"jquery": "^2.0",
"jquery-ui": "~1.10",
"less": "~2",