Improve Google pagespeed score and fix small bugs
This commit is contained in:
parent
b84a94ef55
commit
8440fb036b
14
index.html
14
index.html
|
@ -6,9 +6,9 @@
|
||||||
<title>Notica - Notifications from Your Terminal</title>
|
<title>Notica - Notifications from Your Terminal</title>
|
||||||
|
|
||||||
<![if lt IE 10]>
|
<![if lt IE 10]>
|
||||||
<script src="/assets/js/es5-shim.min.js"></script>
|
<script async src="/assets/js/es5-shim.min.js"></script>
|
||||||
<script src="/assets/js/es5-sham.min.js"></script>
|
<script async src="/assets/js/es5-sham.min.js"></script>
|
||||||
<script src="/assets/js/html5shiv.min.js"></script>
|
<script async src="/assets/js/html5shiv.min.js"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
// Fake console to test in IE<9
|
// Fake console to test in IE<9
|
||||||
if( typeof console == 'undefined' )
|
if( typeof console == 'undefined' )
|
||||||
|
@ -18,10 +18,10 @@
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||||
|
|
||||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/skeleton/2.0.4/skeleton.min.css" integrity="sha256-2YQRJMXD7pIAPHiXr0s+vlRWA7GYJEK0ARns7k2sbHY=" crossorigin="anonymous" />
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/skeleton/2.0.4/skeleton.min.css" integrity="sha256-2YQRJMXD7pIAPHiXr0s+vlRWA7GYJEK0ARns7k2sbHY=" crossorigin="anonymous" media="none" onload="if(media!='all')media='all'" />
|
||||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" integrity="sha256-eZrrJcwDc/3uDhsdt61sL2oOBY362qM3lon1gyExkL0=" crossorigin="anonymous" />
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" integrity="sha256-eZrrJcwDc/3uDhsdt61sL2oOBY362qM3lon1gyExkL0=" crossorigin="anonymous" media="none" onload="if(media!='all')media='all'" />
|
||||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css" integrity="sha256-t2/7smZfgrST4FS1DT0bs/KotCM74XlcqZN5Vu7xlrw=" crossorigin="anonymous" />
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css" integrity="sha256-t2/7smZfgrST4FS1DT0bs/KotCM74XlcqZN5Vu7xlrw=" crossorigin="anonymous" media="none" onload="if(media!='all')media='all'" />
|
||||||
<link href="https://fonts.googleapis.com/css?family=Raleway" rel="stylesheet">
|
<link href="https://fonts.googleapis.com/css?family=Raleway" rel="stylesheet" media="none" onload="if(media!='all')media='all'" />
|
||||||
|
|
||||||
<link rel="stylesheet" href="/assets/css/style.css" type="text/css" media="all" />
|
<link rel="stylesheet" href="/assets/css/style.css" type="text/css" media="all" />
|
||||||
</head>
|
</head>
|
||||||
|
|
|
@ -4,7 +4,7 @@ const bodyParser = require('body-parser');
|
||||||
|
|
||||||
const app = express();
|
const app = express();
|
||||||
|
|
||||||
const host = 'http://0.0.0.0';
|
const host = 'http://127.0.0.1';
|
||||||
const port = 3000;
|
const port = 3000;
|
||||||
|
|
||||||
app.use(bodyParser.urlencoded({ extended: false }));
|
app.use(bodyParser.urlencoded({ extended: false }));
|
||||||
|
|
|
@ -35,7 +35,7 @@ export default class Home extends React.Component {
|
||||||
<p>
|
<p>
|
||||||
Add this line to your <code className="smallcode">.bashrc</code> file:<br />
|
Add this line to your <code className="smallcode">.bashrc</code> file:<br />
|
||||||
<code>
|
<code>
|
||||||
notica() { curl --data "d:$@" https://notica.us/{id}; }
|
notica() { curl --data "d:$*" https://notica.us/{id}; }
|
||||||
</code>
|
</code>
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
|
@ -51,7 +51,7 @@ export default class Home extends React.Component {
|
||||||
<p>
|
<p>
|
||||||
Run this command: <br />
|
Run this command: <br />
|
||||||
<code>
|
<code>
|
||||||
$ echo 'notica() { curl --data "d:$@" https://notica.us/{id}; }' >> ~/.bashrc && source ~/.bashrc
|
$ echo 'notica() { curl --data "d:$*" https://notica.us/{id}; }' >> ~/.bashrc && source ~/.bashrc
|
||||||
</code>
|
</code>
|
||||||
</p>
|
</p>
|
||||||
<p>Go to this link to receive your notifications (bookmark it since it's yours): <Link to={'/' + id}>https://notica.us/{id}</Link></p>
|
<p>Go to this link to receive your notifications (bookmark it since it's yours): <Link to={'/' + id}>https://notica.us/{id}</Link></p>
|
||||||
|
|
|
@ -38,8 +38,8 @@ export default class NotifPage extends React.Component {
|
||||||
|
|
||||||
socket.on('message', (data) => {
|
socket.on('message', (data) => {
|
||||||
console.log("Notification: " + data);
|
console.log("Notification: " + data);
|
||||||
checkperm(Notification.permission);
|
this.checkperm(Notification.permission);
|
||||||
sendNotification(data);
|
this.sendNotification(data);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user