2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-06 09:10:25 +08:00

DEV: Disallow Ember global usage (#16147)

…and sprinkle `// eslint-disable-next-line no-undef` throughout the code where is unavoidable for now
This commit is contained in:
Jarek Radosz 2022-03-09 17:54:07 +01:00 committed by GitHub
parent 2ba602708a
commit 99b2cfe26e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
27 changed files with 58 additions and 6 deletions

View file

@ -29,6 +29,7 @@ export function allCategories() {
let paths = CATEGORIES.join("|");
// Find a list of sections based on what templates are available
// eslint-disable-next-line no-undef
Object.keys(Ember.TEMPLATES).forEach((e) => {
let regexp = new RegExp(`styleguide\/(${paths})\/(\\d+)?\\-?([^\\/]+)$`);
let matches = e.match(regexp);