-
Notifications
You must be signed in to change notification settings - Fork 0
Update from upstream repo joeblau/gitignore.io@master #9
base: master
Are you sure you want to change the base?
Conversation
* Add url params to gitignore.io Added URL Params so keywords can be populated on first load. On loading `templates.json`, it’ll now extract URLParams and filter out those params that exist in the templates. It’ll then “fill” them in the `select2` Search box. Signed-off-by: Robin Malhotra <[email protected]> * Renamed “keywords” to “templates” Signed-off-by: Robin Malhotra <[email protected]>
Public/js/app.js
Outdated
const urlParams = new URLSearchParams(window.location.search); | ||
const preFilledSearchTerms = urlParams.get("templates").split(",").map(val => val.toLowerCase()) | ||
const validIDs = new Set(data.map(datum => datum.id)) | ||
const validPreFilledSearchTerms = preFilledSearchTerms.filter(term => validIDs.has(term)) |
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.
'arrow function syntax (=>)' is only available in ES6 (use 'esversion: 6').
'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).
Missing semicolon.
Public/js/app.js
Outdated
|
||
const urlParams = new URLSearchParams(window.location.search); | ||
const preFilledSearchTerms = urlParams.get("templates").split(",").map(val => val.toLowerCase()) | ||
const validIDs = new Set(data.map(datum => datum.id)) |
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.
'arrow function syntax (=>)' is only available in ES6 (use 'esversion: 6').
'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).
Missing semicolon.
Public/js/app.js
Outdated
}); | ||
|
||
const urlParams = new URLSearchParams(window.location.search); | ||
const preFilledSearchTerms = urlParams.get("templates").split(",").map(val => val.toLowerCase()) |
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.
'arrow function syntax (=>)' is only available in ES6 (use 'esversion: 6').
'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).
Missing semicolon.
Public/js/app.js
Outdated
}); | ||
}); | ||
|
||
const urlParams = new URLSearchParams(window.location.search); |
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.
'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).
* Update #437 - accept "+" letter in url parameter Pull request #437 actually didn't solve the closed issue #435 because I understood the problem wrong. This problem was not about url encoding. `URLSearchParams` object returns invalid gitignore template id not because the object didn't recognize `+` letters, but because it ACTUALLY recognized them and switched them to SPACES(` `). To solve the problem correctly, this commit replaces spaces to `+` letters so the filter is able to find proper ids from template set. * Refactor app.js This commit changes `replace()` function call position to make it more efficient. It doesn't have to be called for each split value in `templates` parameter one by one. No side effects are anticipated. I moved `toLowerCase()` function as well in the same manner, so `map()` eventually became not required anymore. This also unifies code style in `app.js` by adding semicolons to some lines. It's not a critical issue of course, according to ECMA and javascript ASI. I just did it to make it look more unified, as the majority lines of original source code already had semicolons.
* Add translatio n file * Add Persian translation file
Public/js/app.js
Outdated
if (urlParams.get("templates") != null) { | ||
const preFilledSearchTerms = urlParams.get("templates").replace(/\s/g, "+").toLowerCase().split(","); | ||
const validIDs = new Set(data.map(datum => datum.id)); | ||
const validPreFilledSearchTerms = preFilledSearchTerms.filter(term => validIDs.has(term)); |
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.
'arrow function syntax (=>)' is only available in ES6 (use 'esversion: 6').
'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).
Public/js/app.js
Outdated
|
||
if (urlParams.get("templates") != null) { | ||
const preFilledSearchTerms = urlParams.get("templates").replace(/\s/g, "+").toLowerCase().split(","); | ||
const validIDs = new Set(data.map(datum => datum.id)); |
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.
'arrow function syntax (=>)' is only available in ES6 (use 'esversion: 6').
'const' is available in ES6 (use 'esversion: 6') or Mozilla JS extensions (use moz).
Package.swift
Outdated
@@ -21,6 +21,7 @@ let package = Package( | |||
.target( | |||
name: "App", | |||
dependencies: ["Vapor", "Leaf", "LingoVapor"], | |||
path: |
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.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
Bumps [terser](https://github.com/terser/terser) from 5.12.1 to 5.14.2. - [Release notes](https://github.com/terser/terser/releases) - [Changelog](https://github.com/terser/terser/blob/master/CHANGELOG.md) - [Commits](https://github.com/terser/terser/commits) --- updated-dependencies: - dependency-name: terser dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* chore(docker): Optimize dockerfile Optimize dockerfile Signed-off-by: kovacs <[email protected]> * chore(docker): remove STOPSIGNAL remove STOPSIGNAL Signed-off-by: kovacs <[email protected]> * chore(docker): add dump-init add dump-init Signed-off-by: kovacs <[email protected]> * chore(docker): refactor dockerfile refactor dockerfile Signed-off-by: kovacs <[email protected]> * chore(docker): update CMD, add comments update CMD, add comments Signed-off-by: kovacs <[email protected]> * chore(docker): fix docker compose fix docker compose Signed-off-by: kovacs <[email protected]> * chore(docker): rollback dev changes rollback dev changes Signed-off-by: kovacs <[email protected]> Signed-off-by: kovacs <[email protected]>
* Create th.json Thai language for gitignore.io for Thai people * Update Router+Extensions.swift Add thai language
Bumps [loader-utils](https://github.com/webpack/loader-utils) from 2.0.2 to 2.0.4. - [Release notes](https://github.com/webpack/loader-utils/releases) - [Changelog](https://github.com/webpack/loader-utils/blob/v2.0.4/CHANGELOG.md) - [Commits](webpack/loader-utils@v2.0.2...v2.0.4) --- updated-dependencies: - dependency-name: loader-utils dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
[no ci]
Hello!
The upstream repository
joeblau/gitignore.io@master
has some new changes that aren't in this fork. So, here they are, ready to be merged! 🎉If this pull request can be merged without conflict, you can publish your software with these new changes. Otherwise, fix any merge conflicts by clicking the
Resolve Conflicts
button.If you like Backstroke, consider donating to help us pay for infrastructure here. Backstroke is a completely open source project that's free to use, but we survive on sponsorships and donations. Thanks for your support! Help out Backstroke.
Created by Backstroke (I'm a bot!)