Rename type definition file to paper.d.ts.

This commit is contained in:
sasensi 2018-12-03 13:53:30 +01:00 committed by Jürg Lehni
parent bbd65324bc
commit f25690aa91
5 changed files with 5 additions and 4 deletions

View file

@ -22,7 +22,7 @@ gulp.task('zip', ['clean:zip', 'dist'], function() {
gulp.src([
'dist/paper-full*.js',
'dist/paper-core*.js',
'dist/index.d.ts',
'dist/paper.d.ts',
'dist/node/**/*',
'LICENSE.txt',
'examples/**/*',

View file

@ -59,7 +59,7 @@ gulp.task('docs:typescript', function() {
});
// First clean eventually existing type definition...
gulp.task('docs:typescript:clean:before', function() {
return del('dist/index.d.ts');
return del('dist/paper.d.ts');
});
// ...then build the definition...
gulp.task('docs:typescript:build', function() {

View file

@ -115,7 +115,7 @@ const template = fs.readFileSync(__dirname + '/typescript-definition-template.mu
// Render template.
const output = mustache.render(template, context);
// Write output in a file.
fs.writeFileSync(__dirname + '/../../dist/index.d.ts', output, 'utf8');
fs.writeFileSync(__dirname + '/../../dist/paper.d.ts', output, 'utf8');
//

View file

@ -1,4 +1,4 @@
/// <reference path="../../dist/index.d.ts" />
/// <reference path="../../dist/paper.d.ts" />
/**
* This file is used as a way to test auto-generated typescript definition

View file

@ -11,6 +11,7 @@
"bugs": "https://github.com/paperjs/paper.js/issues",
"contributors": ["Jürg Lehni <juerg@scratchdisk.com> (http://scratchdisk.com)", "Jonathan Puckey <jonathan@studiomoniker.com> (http://studiomoniker.com)"],
"main": "dist/paper-full.js",
"types": "dist/paper.d.ts",
"scripts": {
"precommit": "gulp jshint --branch develop",
"prepush": "gulp test --branch develop",