-
Notifications
You must be signed in to change notification settings - Fork 11.4k
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
explorer-client: initialise client app #421
Conversation
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.
This is perfect as a starter CRA
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 think we should remove some stuff that isn't used - "web vitals" & commented out code.
We should also remove the React logo - I think we have some in-progress logos for the network we can use.
@@ -0,0 +1 @@ | |||
/// <reference types="react-scripts" /> |
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.
let's remove this file if it's commented out
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.
this is a special comment for ts to include some types (not sure what exactly was auto generated so I assumed it includes something that is necessary) https://www.typescriptlang.org/docs/handbook/triple-slash-directives.html
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.
It's useful actually. It defines types for various file types like .module.scss, images etc
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.
Good spot. Although strange, this type declaration file is needed to allow TypeScript to work with files that are not typed. If you delete it you'll notice a lot of complaints regarding no corresponding type declarations.
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.
ahh, ok. strange but 👍
@@ -0,0 +1,37 @@ | |||
import type { ReportHandler } from 'web-vitals'; |
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 just remove all the web vitals stuff ? doesn't seem necessary
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.
Since it's under config flag I don't see any reason not to keep it. When this goes to prod probably we will use them to monitor the performance (send the metrics to a service or something) - I am ok to remove it if you insist as well
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've put a comment in the Slack channel to get some thoughts on whether we are likely to be using Google Analytics.
* project init with `create-react-app` with typescript template * added suport for scss * updated readme with some info for development * added linting/formating support with prettier, eslint and stylelint * using `.env` to disable reporting `web-vitals` in prod mode and `console.log` them in dev * disabled `react-scripts` from opening the browser with env variable in `.env.development` (can be overridden in a local env file) * added classnames lib
8987f85
to
7751f7b
Compare
Updated the PR to
|
logos will come end of week from partners, analytics and thus web vitals are an open question, so i think this is good to merge for now. |
create-react-app
with typescript template.env
to disable reportingweb-vitals
in prod mode andconsole.log
them in devreact-scripts
from opening the browser with env variable in.env.development
(can be overridden in a local env file)resolves #420