Skip to content
This repository was archived by the owner on Oct 4, 2020. It is now read-only.

Commit 205433b

Browse files
committed
Initial DOM effect.
0 parents  commit 205433b

File tree

6 files changed

+88
-0
lines changed

6 files changed

+88
-0
lines changed

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/.*
2+
!/.gitignore
3+
bower_components/
4+
node_modules/
5+
output/
6+
tmp/

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# Module Documentation
2+
3+
## Module DOM
4+
5+
### Types
6+
7+
data DOM :: !
8+
9+
10+

bower.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"name": "purescript-dom",
3+
"version": "0.0.0",
4+
"description": "PureScript interface for the DOM.",
5+
"license": "MIT"
6+
}
7+

gulpfile.js

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
'use strict'
2+
3+
var gulp = require('gulp')
4+
, purescript = require('gulp-purescript')
5+
;
6+
7+
var paths = {
8+
src: 'src/**/*.purs',
9+
bowerSrc: [
10+
'bower_components/purescript-*/src/**/*.purs',
11+
'bower_components/purescript-*/src/**/*.purs.hs'
12+
],
13+
dest: '',
14+
docsDest: 'README.md'
15+
};
16+
17+
var options = {};
18+
19+
var compile = function(compiler) {
20+
var psc = compiler(options);
21+
psc.on('error', function(e) {
22+
console.error(e.message);
23+
psc.end();
24+
});
25+
return gulp.src([paths.src].concat(paths.bowerSrc))
26+
.pipe(psc)
27+
.pipe(gulp.dest(paths.dest));
28+
};
29+
30+
gulp.task('make', function() {
31+
return compile(purescript.pscMake);
32+
});
33+
34+
gulp.task('browser', function() {
35+
return compile(purescript.psc);
36+
});
37+
38+
gulp.task('docs', function() {
39+
return gulp.src(paths.src)
40+
.pipe(purescript.docgen())
41+
.pipe(gulp.dest(paths.docsDest));
42+
});
43+
44+
gulp.task('watch-browser', function() {
45+
gulp.watch(paths.src, ['browser', 'docs']);
46+
});
47+
48+
gulp.task('watch-make', function() {
49+
gulp.watch(paths.src, ['make', 'docs']);
50+
});
51+
52+
gulp.task('default', ['make', 'docs']);

package.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"name": "purescript-dom",
3+
"version": "0.0.0",
4+
"description": "PureScript interface for the DOM.",
5+
"license": "MIT",
6+
"devDependencies": {
7+
"gulp": "^3.8.1",
8+
"gulp-purescript": "0.0.8"
9+
}
10+
}

src/DOM.purs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module DOM where
2+
3+
foreign import data DOM :: !

0 commit comments

Comments
 (0)