about summary refs log tree commit diff
path: root/test
diff options
context:
space:
mode:
authorPatryk Niedźwiedziński <pniedzwiedzinski19@gmail.com>2020-01-28 19:08:33 +0100
committerGitHub <noreply@github.com>2020-01-28 19:08:33 +0100
commit576d08d06bd0743d3912770fff4d5b1e38c0f576 (patch)
tree651b1bf75705723622c75d9b1eee54c4ab7e6bfc /test
parent3cf1e858dfad1d8f3ba7079e7e0b249c1cdfd5f5 (diff)
downloadkronika-576d08d06bd0743d3912770fff4d5b1e38c0f576.tar.gz
kronika-576d08d06bd0743d3912770fff4d5b1e38c0f576.zip
Add headers (#6)
* Add api building

* Add headers

* Change path

* Add file

* Move script
Diffstat (limited to 'test')
-rwxr-xr-xtest/_headers2
-rw-r--r--test/package.json2
2 files changed, 3 insertions, 1 deletions
diff --git a/test/_headers b/test/_headers
new file mode 100755
index 0000000..f2d986b
--- /dev/null
+++ b/test/_headers
@@ -0,0 +1,2 @@
+/*
+    Access-Control-Allow-Origin: *
diff --git a/test/package.json b/test/package.json
index 52960ed..74665d2 100644
--- a/test/package.json
+++ b/test/package.json
@@ -8,7 +8,7 @@
     "kronikarz": "^2.0.0"
   },
   "scripts": {
-    "build": "mkdir -p ../api/api && touch ../api/api/posts.json && node -r esm build.js",
+    "build": "mkdir -p ../api/api && touch ../api/api/posts.json && node -r esm build.js && cp _headers ../api",
     "test": "./validator.sh"
   },
   "keywords": [],