Skip to content

Commit

Permalink
Basic setup TypeScript linkeddata#355
Browse files Browse the repository at this point in the history
  • Loading branch information
joepio committed Oct 1, 2019
1 parent 5c018ac commit e64ae06
Show file tree
Hide file tree
Showing 5 changed files with 6,238 additions and 4 deletions.
12 changes: 9 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@
"@babel/plugin-transform-runtime": "^7.5.5",
"@babel/preset-env": "^7.5.5",
"@babel/register": "^7.5.5",
"@types/chai": "^4.2.3",
"@types/mocha": "^5.2.7",
"awesome-typescript-loader": "^5.2.1",
"babel-loader": "^8.0.6",
"chai": "^4.2.0",
"diff": "^4.0.1",
Expand All @@ -59,6 +62,9 @@
"rimraf": "^3.0.0",
"sinon": "^7.4.1",
"sinon-chai": "^3.3.0",
"source-map-loader": "^0.2.4",
"ts-node": "^8.4.1",
"typescript": "^3.6.3",
"webpack": "^4.39.2",
"webpack-cli": "^3.3.6",
"webpack-dev-server": "^3.8.0",
Expand Down Expand Up @@ -87,9 +93,9 @@
"test:serialize:11": "cd ./tests/serialize && node ./data.js -in=structures.n3 -format=application/rdf+xml -out=,structures.xml && node diff ,structures.xml t11-ref.xml",
"test:serialize:12": "cd ./tests/serialize && node ./data.js -in=structures.n3 -format=text/turtle -out=,structures.ttl && node diff ,structures.ttl t12-ref.ttl",
"test:serialize:13": "cd ./tests/serialize && node ./data.js -in=structures.n3 -format=application/n-triples -out=,structures.nt && node ./data.js -format=application/n-triples -in=,structures.nt -format=text/turtle -out=,structures.nt.ttl && node diff ,structures.nt.ttl t13-ref.ttl",
"test:unit": "mocha --growl --require @babel/register tests/unit/**-test.js",
"test:unit:egp": "mocha --require @babel/register tests/unit/fetcher-egp-test.js",
"test:unit:dev": "mocha --watch --growl --require @babel/register tests/unit/**-test.js"
"test:unit": "mocha --growl --require @babel/register --require ts-node/register tests/unit/**-test.js",
"test:unit:egp": "mocha --require @babel/register --require ts-node/register tests/unit/fetcher-egp-test.js",
"test:unit:dev": "mocha --watch --growl --require @babel/register --require ts-node/register tests/unit/**-test.js"
},
"files": [
".babelrc",
Expand Down
File renamed without changes.
11 changes: 11 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"compilerOptions": {
"outDir": "./dist",
"allowJs": true,
"target": "es5",
"module": "commonjs"
},
"include": [
"./src/**/*"
]
}
10 changes: 9 additions & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module.exports = (env, args) => {
return {
mode: 'production',
entry: [
'./src/index.js'
'./src/index.ts'
],
output: {
path: path.join(__dirname, '/dist/'),
Expand All @@ -15,10 +15,18 @@ module.exports = (env, args) => {
},
module: {
rules: [
{
test: /\.tsx?$/,
loader: "awesome-typescript-loader"
},
{
test: /\.js$/,
loader: 'babel-loader',
exclude: /node_modules/
},
{
test: /\.js$/,
loader: "source-map-loader"
}
]
},
Expand Down
Loading

0 comments on commit e64ae06

Please sign in to comment.