While refactoring the login form component I found many inconsistent
ways of importing the list of locales. So I decided to refactor the
imports altogether. Don't use `process.env` to import locales!
This will allow us to use this.$scrollTo in components. I'm now also
using this in the mixin. With so many `this`s it gets horribly
difficult to properly test the mixin in isolation. So I decided to test
the mixin on the component directly.
So nuxt's default scrollBehavior seems to have some kind of "scroll to
anchor" already built in. Unfortunately we cannot use it, because the
the anchor is not yet in the DOM when the scroll behavior is called.
So the justification for this change is:
1. Remove scrollBehavior from `nuxt.config.js` it's deprecated to put it
there.
2. Also *don't* use the default scrollbehavior because of the reasons
above ☝️
Instead I assume to always scroll to the top. This might be undesired
sometimes but let's keep a watchful eye and define the behavior if
needed.
This should make new contributors aware that the Styleguide exists and
maybe maybe even encourage people to contribute to the Styleguide.
Also this enabled `yarn run dev:styleguide` to build the `webapp/` along
with the styleguide.
NuxtJS wants to write into .nuxt. If the docker container writes into
.nuxt it will have the file permissions of the docker container user
even on the host system. So on the host system you cannot remove the
folder .nuxt anymore. This gets in the way of running NuxtJS on the host
system.
@appinteractive we have `yarn run lint` on our build server. I would say
this is enough to enforce linting. I get slowed down a little during
development. Instead of runing `yarn run lint --fix` every time I save, I
would like to `yarn run lint --fix` all in one before I commit.
`git diff b32c85b2de014770d07df8a642616b016cf69b50..46aecd612018db490fb3d6f91572be848371b32e -- webapp/nuxt.config.js`
showed me that I removed headers because I didn't thought they are
relevant. Now the proxy route `/activityPub` is not reachable anymore.
@Mastercuber I hope this does not interfere with anything that uses
`/.well-known`, too. Would you suggest to proxy everything related to
webfinger to the backend?
My motivation for proxying webfinger is that you can search for
`someuser@nitro-staging.human-connection.org` instead of `someuser@nitro-staging.human-connection.org/activityPub`. This is better user experience in my opinion.