add a static file example
This commit is contained in:
parent
9b3e71c496
commit
a27a5e9370
4 changed files with 15 additions and 5 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1,2 +1,3 @@
|
|||
__pycache__/
|
||||
venv/
|
||||
.tern-port
|
||||
|
|
3
watcher/static/hello.js
Normal file
3
watcher/static/hello.js
Normal file
|
@ -0,0 +1,3 @@
|
|||
function sayHello() {
|
||||
alert("Hello World");
|
||||
}
|
3
watcher/static/index.css
Normal file
3
watcher/static/index.css
Normal file
|
@ -0,0 +1,3 @@
|
|||
h1 {
|
||||
color: blue;
|
||||
}
|
|
@ -1,7 +1,10 @@
|
|||
<html>
|
||||
<head>
|
||||
<script type = "text/javascript"
|
||||
src = "{{ url_for('static', filename = 'hello.js') }}" ></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>TEST</h1>
|
||||
<input type = "button" onclick = "sayHello()" value = "Say Hello" />
|
||||
</body>
|
||||
</html>
|
||||
|
|
Loading…
Reference in a new issue