Some important commit messages:
```
Fix youtu.be not being embedded
And also try to maintain the old behaviour matching
`provider.provider_url`.
```
```
Remove confusing code comments and obsolete code
I discovered that the behaviour of no duplicate notifications being send
out is caused by the frontend: When the editor reads html from the
backend, it will parse hashtags and mentions as ordinary links, not as
their respective nodes during editing. Also, we don't have to worry
about duplicate ids being found: The cypher statement will implicitly
suppress duplicate notification nodes for the same user.
So let's remove the code to avoid confusing the next developer.
```
```
Test editor.getHTML()
I do this because I'm not able to test the content of `this.editor` from
a wrapper of `vue-test-utils`. If I call `this.editor.getHTML` directly
and use it as a computed property `renderedContent` to populate a `<div
v-html="renderedContent" />` this will not work for the embeds. So, my
current best bet is to test the editor object isolated from a real
component. ;(
```
```
Add core-js as explicit dependency
Because of build errors on Travis.
See: https://stackoverflow.com/a/55313456
Remove as soon as this issue is resolved:
https://github.com/storybookjs/storybook/issues/7591
```
```
Refactor: Keep Runtime-only builds
See: https://vuejs.org/v2/guide/installation.html#Runtime-Compiler-vs-Runtime-only
```
Backend
Installation with Docker
Run the following command to install everything through docker.
The installation takes a bit longer on the first pass or on rebuild ...
$ docker-compose up
# rebuild the containers for a cleanup
$ docker-compose up --build
Wait a little until your backend is up and running at http://localhost:4000/.
Installation without Docker
For the local installation you need a recent version of node
(>= v10.12.0).
Install node dependencies with yarn:
$ cd backend
$ yarn install
Copy Environment Variables:
# in backend/
$ cp .env.template .env
Configure the new file according to your needs and your local setup. Make sure a local Neo4J instance is up and running.
Start the backend for development with:
$ yarn run dev
or start the backend in production environment with:
yarn run start
For e-mail delivery, please configure at least SMTP_HOST and SMTP_PORT in
your .env configuration file.
Your backend is up and running at http://localhost:4000/
This will start the GraphQL service by default on localhost:4000 where you
can issue GraphQL requests or access GraphQL Playground in the browser.
Seed Database
If you want your backend to return anything else than an empty response, you need to seed your database:
{% tabs %} {% tab title="Docker" %}
In another terminal run:
$ docker-compose exec backend yarn run db:seed
To reset the database run:
$ docker-compose exec backend yarn run db:reset
# you could also wipe out your neo4j database and delete all volumes with:
$ docker-compose down -v
{% endtab %}
{% tab title="Without Docker" %} Run:
$ yarn run db:seed
To reset the database run:
$ yarn run db:reset
{% endtab %} {% endtabs %}
Testing
Beware: We have no multiple database setup at the moment. We clean the database after each test, running the tests will wipe out all your data!
{% tabs %} {% tab title="Docker" %}
Run the jest tests:
$ docker-compose exec backend yarn run test:jest
Run the cucumber features:
$ docker-compose exec backend yarn run test:cucumber
{% endtab %}
{% tab title="Without Docker" %}
Run the jest tests:
$ yarn run test:jest
Run the cucumber features:
$ yarn run test:cucumber
{% endtab %} {% endtabs %}
