-
Notifications
You must be signed in to change notification settings - Fork 388
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1856 from yuvipanda/closure
Rewrite the frontend
- Loading branch information
Showing
71 changed files
with
2,038 additions
and
2,367 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,48 @@ | ||
module.exports = { | ||
env: { | ||
browser: true, | ||
jquery: true, | ||
node: true, | ||
es6: true, | ||
"jest/globals": true, | ||
}, | ||
extends: ["eslint:recommended"], | ||
ignorePatterns: ["**/dist"], | ||
parser: "@babel/eslint-parser", | ||
plugins: ["jest"], | ||
rules: {}, | ||
es2021: true, | ||
}, | ||
extends: ["eslint:recommended", "plugin:react/recommended"], | ||
ignorePatterns: ["dist"], | ||
overrides: [ | ||
{ | ||
env: { | ||
node: true, | ||
}, | ||
files: [".eslintrc.{js,cjs}"], | ||
parserOptions: { | ||
sourceType: "script", | ||
}, | ||
}, | ||
{ | ||
files: ["**/*.test.js", "**/*.test.jsx"], | ||
env: { | ||
jest: true, | ||
node: true, | ||
}, | ||
}, | ||
], | ||
parserOptions: { | ||
ecmaVersion: "latest", | ||
sourceType: "module", | ||
}, | ||
plugins: ["react"], | ||
rules: { | ||
"react/react-in-jsx-scope": "off", | ||
"react/jsx-uses-react": "off", | ||
// Temporarily turn off prop-types | ||
"react/prop-types": "off", | ||
"no-unused-vars": ["error", { args: "after-used" }], | ||
}, | ||
ignorePatterns: [ | ||
"jupyterhub_fancy_profiles/static/*.js", | ||
"webpack.config.js", | ||
"babel.config.js", | ||
], | ||
settings: { | ||
react: { | ||
version: "detect", | ||
}, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -81,6 +81,7 @@ coverage.xml | |
*.py,cover | ||
.hypothesis/ | ||
.pytest_cache/ | ||
coverage | ||
|
||
# Translations | ||
*.mo | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
{ | ||
"presets": ["@babel/preset-env"] | ||
"presets": [ | ||
"@babel/preset-env", | ||
["@babel/preset-react", { "runtime": "automatic" }] | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import json | ||
|
||
from ..base import BaseHandler | ||
|
||
|
||
class RepoProvidersHandlers(BaseHandler): | ||
"""Serve config""" | ||
|
||
async def get(self): | ||
config = [ | ||
repo_provider_class.display_config | ||
for repo_provider_class in self.settings["repo_providers"].values() | ||
] | ||
self.set_header("Content-type", "application/json") | ||
self.write(json.dumps(config)) |
Oops, something went wrong.