đ Open source, privacy-first web analytics â a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!
TypeScript chartsclickhousedockergdprgoogle-analyticsmetricsmonitoringmysqlnestjsprivacyredisself-hostedselfhostedstatisticstailwindcssweb-analyticswebanalyticswebsite
Initial commit
Blaumaus898c4e95c874
diff --git a/.gitignore b/.gitignoreindex 67045665d..00625e6a4 100644--- a/.gitignore+++ b/.gitignore@@ -102,3 +102,28 @@ dist# TernJS port file.tern-port+# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.++# dependencies+/node_modules+/.pnp+.pnp.js++# testing+/coverage++# production+/build++# misc+.DS_Store+.env.local+.env.development.local+.env.test.local+.env.production.local++npm-debug.log*+yarn-debug.log*+yarn-error.log*++package-lock.jsondiff --git a/README.md b/README.mdindex 373a73978..0c83cde2c 100644--- a/README.md+++ b/README.md@@ -1 +1,70 @@-# analytics_pwa\ No newline at end of file+# Getting Started with Create React App++This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).++## Available Scripts++In the project directory, you can run:++### `npm start`++Runs the app in the development mode.\+Open [http://localhost:3000](http://localhost:3000) to view it in the browser.++The page will reload if you make edits.\+You will also see any lint errors in the console.++### `npm test`++Launches the test runner in the interactive watch mode.\+See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.++### `npm run build`++Builds the app for production to the `build` folder.\+It correctly bundles React in production mode and optimizes the build for the best performance.++The build is minified and the filenames include the hashes.\+Your app is ready to be deployed!++See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.++### `npm run eject`++**Note: this is a one-way operation. Once you `eject`, you canât go back!**++If you arenât satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.++Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point youâre on your own.++You donât have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldnât feel obligated to use this feature. However we understand that this tool wouldnât be useful if you couldnât customize it when you are ready for it.++## Learn More++You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).++To learn React, check out the [React documentation](https://reactjs.org/).++### Code Splitting++This section has moved here: [https://facebook.github.io/create-react-app/docs/code-splitting](https://facebook.github.io/create-react-app/docs/code-splitting)++### Analyzing the Bundle Size++This section has moved here: [https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size](https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size)++### Making a Progressive Web App++This section has moved here: [https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app](https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app)++### Advanced Configuration++This section has moved here: [https://facebook.github.io/create-react-app/docs/advanced-configuration](https://facebook.github.io/create-react-app/docs/advanced-configuration)++### Deployment++This section has moved here: [https://facebook.github.io/create-react-app/docs/deployment](https://facebook.github.io/create-react-app/docs/deployment)++### `npm run build` fails to minify++This section has moved here: [https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify](https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify)diff --git a/jsconfig.json b/jsconfig.jsonnew file mode 100644index 000000000..1a7e339c4--- /dev/null+++ b/jsconfig.json@@ -0,0 +1,5 @@+{+ "compilerOptions": {+ "baseUrl": "src"+ }+}\ No newline at end of filediff --git a/package.json b/package.jsonnew file mode 100644index 000000000..9572c4cc3--- /dev/null+++ b/package.json@@ -0,0 +1,45 @@+{+ "name": "analytics_pwa",+ "version": "0.1.0",+ "private": true,+ "dependencies": {+ "@material-ui/core": "^4.11.3",+ "@testing-library/jest-dom": "^5.11.9",+ "@testing-library/react": "^11.2.5",+ "@testing-library/user-event": "^12.8.3",+ "axios": "^0.21.1",+ "node-sass": "^5.0.0",+ "react": "^17.0.1",+ "react-dom": "^17.0.1",+ "react-redux": "^7.2.2",+ "react-router-dom": "^5.2.0",+ "react-scripts": "4.0.3",+ "redux": "^4.0.5",+ "redux-saga": "^1.1.3",+ "web-vitals": "^1.1.1"+ },+ "scripts": {+ "start": "react-scripts start",+ "build": "react-scripts build",+ "test": "react-scripts test",+ "eject": "react-scripts eject"+ },+ "eslintConfig": {+ "extends": [+ "react-app",+ "react-app/jest"+ ]+ },+ "browserslist": {+ "production": [+ ">0.2%",+ "not dead",+ "not op_mini all"+ ],+ "development": [+ "last 1 chrome version",+ "last 1 firefox version",+ "last 1 safari version"+ ]+ }+}diff --git a/public/favicon.ico b/public/favicon.iconew file mode 100644index 000000000..a11777cc4Binary files /dev/null and b/public/favicon.ico differdiff --git a/public/index.html b/public/index.htmlnew file mode 100644index 000000000..aa069f27c--- /dev/null+++ b/public/index.html@@ -0,0 +1,43 @@+<!DOCTYPE html>+<html lang="en">+ <head>+ <meta charset="utf-8" />+ <link rel="icon" href="%PUBLIC_URL%/favicon.ico" />+ <meta name="viewport" content="width=device-width, initial-scale=1" />+ <meta name="theme-color" content="#000000" />+ <meta+ name="description"+ content="Web site created using create-react-app"+ />+ <link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />+ <!--+ manifest.json provides metadata used when your web app is installed on a+ user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/+ -->+ <link rel="manifest" href="%PUBLIC_URL%/manifest.json" />+ <!--+ Notice the use of %PUBLIC_URL% in the tags above.+ It will be replaced with the URL of the `public` folder during the build.+ Only files inside the `public` folder can be referenced from the HTML.++ Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will+ work correctly both with client-side routing and a non-root public URL.+ Learn how to configure a non-root public URL by running `npm run build`.+ -->+ <title>React App</title>+ </head>+ <body>+ <noscript>You need to enable JavaScript to run this app.</noscript>+ <div id="root"></div>+ <!--+ This HTML file is a template.+ If you open it directly in the browser, you will see an empty page.++ You can add webfonts, meta tags, or analytics to this file.+ The build step will place the bundled scripts into the <body> tag.++ To begin the development, run `npm start` or `yarn start`.+ To create a production bundle, use `npm run build` or `yarn build`.+ -->+ </body>+</html>diff --git a/public/logo192.png b/public/logo192.pngnew file mode 100644index 000000000..fc44b0a37Binary files /dev/null and b/public/logo192.png differdiff --git a/public/logo512.png b/public/logo512.pngnew file mode 100644index 000000000..a4e47a654Binary files /dev/null and b/public/logo512.png differdiff --git a/public/manifest.json b/public/manifest.jsonnew file mode 100644index 000000000..080d6c77a--- /dev/null+++ b/public/manifest.json@@ -0,0 +1,25 @@+{+ "short_name": "React App",+ "name": "Create React App Sample",+ "icons": [+ {+ "src": "favicon.ico",+ "sizes": "64x64 32x32 24x24 16x16",+ "type": "image/x-icon"+ },+ {+ "src": "logo192.png",+ "type": "image/png",+ "sizes": "192x192"+ },+ {+ "src": "logo512.png",+ "type": "image/png",+ "sizes": "512x512"+ }+ ],+ "start_url": ".",+ "display": "standalone",+ "theme_color": "#000000",+ "background_color": "#ffffff"+}diff --git a/public/robots.txt b/public/robots.txtnew file mode 100644index 000000000..e9e57dc4d--- /dev/null+++ b/public/robots.txt@@ -0,0 +1,3 @@+# https://www.robotstxt.org/robotstxt.html+User-agent: *+Disallow:diff --git a/src/App.js b/src/App.jsnew file mode 100644index 000000000..21a61f4aa--- /dev/null+++ b/src/App.js@@ -0,0 +1,16 @@+import React from 'react'+import { Switch, Route, Redirect } from 'react-router-dom'+import routes from 'routes'++import MainPage from 'pages/MainPage'++export default () => {+ return (+ <Switch>+ <Route path={routes.signin} component={<></>} exact />+ <Route path={routes.signup} component={<></>} exact />+ <Route path={routes.main} component={MainPage} exact />+ <Redirect to={routes.main} />+ </Switch>+ )+}\ No newline at end of filediff --git a/src/App.scss b/src/App.scssnew file mode 100644index 000000000..74b5e0534--- /dev/null+++ b/src/App.scss@@ -0,0 +1,38 @@+.App {+ text-align: center;+}++.App-logo {+ height: 40vmin;+ pointer-events: none;+}++@media (prefers-reduced-motion: no-preference) {+ .App-logo {+ animation: App-logo-spin infinite 20s linear;+ }+}++.App-header {+ background-color: #282c34;+ min-height: 100vh;+ display: flex;+ flex-direction: column;+ align-items: center;+ justify-content: center;+ font-size: calc(10px + 2vmin);+ color: white;+}++.App-link {+ color: #61dafb;+}++@keyframes App-logo-spin {+ from {+ transform: rotate(0deg);+ }+ to {+ transform: rotate(360deg);+ }+}diff --git a/src/actions/auth/index.js b/src/actions/auth/index.jsnew file mode 100644index 000000000..eaaeec6b6--- /dev/null+++ b/src/actions/auth/index.js@@ -0,0 +1,5 @@+import { types } from './types'++export const actions = {++}\ No newline at end of filediff --git a/src/actions/auth/types.js b/src/actions/auth/types.jsnew file mode 100644index 000000000..e69de29bbdiff --git a/src/components/Footer/index.jsx b/src/components/Footer/index.jsxnew file mode 100644index 000000000..0af2f42f1--- /dev/null+++ b/src/components/Footer/index.jsx@@ -0,0 +1,15 @@+import React from 'react'+import './styles.scss'+import { Link } from 'react-router-dom'++export default () => {+ return (+ <footer className={classes.footer}>+ <Link to="/test">Test</Link>+ |+ <Link to="/test">Test</Link>+ |+ <Link to="/test">Test</Link>+ </footer>+ );+}\ No newline at end of filediff --git a/src/components/Footer/styles.scss b/src/components/Footer/styles.scssnew file mode 100644index 000000000..e69de29bbdiff --git a/src/components/Header/index.jsx b/src/components/Header/index.jsxnew file mode 100644index 000000000..e69de29bbdiff --git a/src/components/Header/styles.scss b/src/components/Header/styles.scssnew file mode 100644index 000000000..e69de29bbdiff --git a/src/index.js b/src/index.jsnew file mode 100644index 000000000..4ec3c6e80--- /dev/null+++ b/src/index.js@@ -0,0 +1,24 @@+import React from 'react'+import ReactDOM from 'react-dom'+import { BrowserRouter } from 'react-router-dom'+// import { store } from 'store'+// import { Provider } from 'react-redux'+import './index.scss'+import App from './App'+import reportWebVitals from './reportWebVitals'++ReactDOM.render(+ <React.StrictMode>+ {/* <Provider store={store}> */}+ <BrowserRouter>+ <App />+ </BrowserRouter>+ {/* </Provider> */}+ </React.StrictMode>,+ document.getElementById('root')+)++// If you want to start measuring performance in your app, pass a function+// to log results (for example: reportWebVitals(console.log))+// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals+reportWebVitals()\ No newline at end of filediff --git a/src/index.scss b/src/index.scssnew file mode 100644index 000000000..ec2585e8c--- /dev/null+++ b/src/index.scss@@ -0,0 +1,13 @@+body {+ margin: 0;+ font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',+ 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',+ sans-serif;+ -webkit-font-smoothing: antialiased;+ -moz-osx-font-smoothing: grayscale;+}++code {+ font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',+ monospace;+}diff --git a/src/pages/Auth/ForgotPassword/index.jsx b/src/pages/Auth/ForgotPassword/index.jsxnew file mode 100644index 000000000..e69de29bbdiff --git a/src/pages/Auth/Signin/index.jsx b/src/pages/Auth/Signin/index.jsxnew file mode 100644index 000000000..e69de29bbdiff --git a/src/pages/Auth/Signup/index.jsx b/src/pages/Auth/Signup/index.jsxnew file mode 100644index 000000000..e69de29bbdiff --git a/src/pages/MainPage/index.jsx b/src/pages/MainPage/index.jsxnew file mode 100644index 000000000..c1090b7cb--- /dev/null+++ b/src/pages/MainPage/index.jsx@@ -0,0 +1,10 @@+import React from 'react'++export default () => {+ return (+ <div>+ <h1>The initial page!</h1>+ <p>Hello there</p>+ </div>+ )+}\ No newline at end of filediff --git a/src/pages/MainPage/styles.scss b/src/pages/MainPage/styles.scssnew file mode 100644index 000000000..e69de29bbdiff --git a/src/pages/UserSettings/index.jsx b/src/pages/UserSettings/index.jsxnew file mode 100644index 000000000..e69de29bbdiff --git a/src/reducers/auth.js b/src/reducers/auth.jsnew file mode 100644index 000000000..2a6675d82--- /dev/null+++ b/src/reducers/auth.js@@ -0,0 +1,16 @@+import { types } from 'actions/auth/types'++const initialState = {+ redirectPath: null,+ authenticated: false,+ loading: true,+ user: null+}++export default (state = initialState, { type, payload }) => {+ switch (type) {++ default:+ return state+ }+}\ No newline at end of filediff --git a/src/reducers/index.js b/src/reducers/index.jsnew file mode 100644index 000000000..4df645a17--- /dev/null+++ b/src/reducers/index.js@@ -0,0 +1,4 @@+import { combineReducers } from 'redux'+import auth from './auth'++export default combineReducers({ auth })\ No newline at end of filediff --git a/src/reportWebVitals.js b/src/reportWebVitals.jsnew file mode 100644index 000000000..5253d3ad9--- /dev/null+++ b/src/reportWebVitals.js@@ -0,0 +1,13 @@+const reportWebVitals = onPerfEntry => {+ if (onPerfEntry && onPerfEntry instanceof Function) {+ import('web-vitals').then(({ getCLS, getFID, getFCP, getLCP, getTTFB }) => {+ getCLS(onPerfEntry);+ getFID(onPerfEntry);+ getFCP(onPerfEntry);+ getLCP(onPerfEntry);+ getTTFB(onPerfEntry);+ });+ }+};++export default reportWebVitals;diff --git a/src/routes.js b/src/routes.jsnew file mode 100644index 000000000..2d15be380--- /dev/null+++ b/src/routes.js@@ -0,0 +1,5 @@+export default Object.freeze({+ signin: '/sign-in',+ signup: '/sign-up',+ main: '/',+})\ No newline at end of filediff --git a/src/sagas/.gitsave b/src/sagas/.gitsavenew file mode 100644index 000000000..e69de29bbdiff --git a/src/store/index.js b/src/store/index.jsnew file mode 100644index 000000000..3963162f1--- /dev/null+++ b/src/store/index.js@@ -0,0 +1,14 @@+import { createStore, applyMiddleware, compose } from 'redux'+import createSagaMiddleware from 'redux-saga'+import root_reducer from 'reducers'+// import root_saga from 'sagas'++// const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose+// const sagaMiddleware = createSagaMiddleware()++export const store = createStore(+ root_reducer,+ // composeEnhancers(applyMiddleware(sagaMiddleware))+)++// sagaMiddleware.run(root_saga)\ No newline at end of file