-
Notifications
You must be signed in to change notification settings - Fork 213
unpkg usage #56
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
base: master
Are you sure you want to change the base?
unpkg usage #56
Conversation
tslint-config-prettier is necessary to make prettier play nice with tslint.
this commit formats src/* and tests/* according to prettier so that it would be a starting point for all commits from now on ( if not done prettier would do it anayway once a change occurs in one of those files, and cloud the actual change made by that commit)
the function keyword makes code more readable when the function's body is large, one tends to lose track while reading large arrow functions.
README.md
Outdated
@@ -37,7 +41,17 @@ console.log(`The dominant color is ${result[0].color} with ${result[0].count} oc | |||
console.log(`The secondary color is ${result[1].color} with ${result[1].count} occurrence(s)`) | |||
// => The secondary color is rgb(255,0,0) with 1 occurrence(s) | |||
``` | |||
The `script` tag way: |
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.
Using a
script
tag:
README.md
Outdated
@@ -58,6 +72,7 @@ In order to achieve greater speed, you can have `rgbaster` scale down the image | |||
```js | |||
const result = await analyze('/image.png', { scale: 0.6 }) | |||
``` | |||
ps: the options also apply for the `script` version. |
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.
I don't think this line is needed.
@@ -0,0 +1,6 @@ | |||
{ | |||
"trailingComma": "es5", | |||
"tabWidth": 2, |
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.
isn't 2
the default?
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.
I just wanted it to be explicit, I will remove it.
@a-hariti Looks like your PRs have some cross pollination of commits? Mind separating them out into distinct PRs? Thanks! |
I'm afraid I don't get the meaning of "cross pollination of commits", but I will try to fix these issues. |
I am just saying that you have two PRs, one called "unpkg" and one called "prettier", yet this commit (the one about "unpkg") had commits from the other PR. If you can make sure each PR only has one concern, it'll make my job easier when it comes time to merge. Thanks! |
I will be careful next time. sometimes I change branches and forget that I made a certain change elsewhere (and I don't have a very strong git fu [yet] to clean the mess 😆) |
Let me know if you'd like a hand :) |
document CDN usage through upkg