-
Notifications
You must be signed in to change notification settings - Fork 248
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Es6 #163
Es6 #163
Conversation
Current coverage is 69.46% (diff: 69.46%)
|
presets: [ | ||
"latest", | ||
], | ||
"plugins": [ "istanbul" ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please don't use double quotes in property name
}, | ||
emitError: false, | ||
failOnError: false, | ||
"rules": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please remove this rule
ecmaVersion: 6, | ||
sourceType: "module" | ||
}, | ||
emitError: false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please set true on emitError and failOnError
}, | ||
jscs: { | ||
validateIndentation: 2, | ||
emitErrors: false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please set true on emitError and failOnHint
let scale = attrs.scale > 0 ? attrs.scale : 1; | ||
let canvasid = attrs.canvasid || 'pdf-canvas'; | ||
let canvas = $document[0].getElementById(canvasid); | ||
var creds = attrs.usecredentials; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we use let
also for creds
, ctx
and windowEl
?
}, | ||
"keywords": [ | ||
"pdf", | ||
"angular", | ||
"directive" | ||
], | ||
"license": "MIT", | ||
"dependencies": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use peerDependencies
instead of dependencies
node <= 0.xx doesn't support es6 syntax ref: http://node.green/
0ecc917
to
16826dd
Compare
In order to use es6 in the package we need a module bundler (webpack) that transpile our code using babel. To do that we did: - added bumped to manage releases - updated travis test - updated package.json and bower.json in order to work with webpack - added a CHANGELOG page - updated index.html - added many fix on module - added eslint and remove jsonhint - removed bower dependency - updated documentation - added automatic gh-pages deploy - added angularjs and pdfjs as peerDependencies aside note of duplicated dependencies in package.json: angularjs and pdfjs are in both list because we need to alert user if they lack AND for developing/testig purposes ref: sayanee#90
Generate code coverage using Istanbul
@simobasso can we also have an |
Could I make a small suggestion since you are already writing this.
Maybe also a new callback at the start of the |
Can I fork
An issue I had around the |
Thanks for the feedback @rhyskoedijk, this speeds up our testing-before-merging process 😉 Our roadmap on the project is the following:
Starting from tomorrow we will fix conflicts in this PR in order to merge as soon as possible, so you can fork the Thanks for your help |
publicPath: isProd ? '/' : 'http://localhost:8080/', | ||
filename: "angular-pdf.min.js", | ||
library: "pdf", | ||
libraryTarger: "umd", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@simobasso I think this property is libraryTarget
instead of libraryTarger
package.json
Outdated
"build": "grunt", | ||
"start": "http-server ./example -p 8081", | ||
"test": "grunt --verbose" | ||
"build": "rimraf dist && webpack --progress --profile", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@simobasso can we install rimraf
as devDependency?
@simobasso what do you think about this branch? |
just merge it ;) |
close in favor of #184 |
move whole package to es6