Simple forum software for building great communities.
Go to file
Toby Zerner f255d318ef Add multiple UrlGenerator classes for forum/api/admin
Spent quite a while looking into the best solution here and ended up going with three separate classes. Thanks to @Luceos for the PR that got this rolling (#518). My reasoning is:

- The task of routing and URL generation is independent for each section of the app. Take Flarum\Api\Users\IndexAction for example. I don't want to generate a URL to a Flarum route... I specifically want to generate a URL to an API route. So there should be a class with that specific responsibility.
- In fact, each URL generator is slightly different, because we need to add a certain prefix to the start (e.g. /api)
- This also allows us to get rid of the "flarum.api" prefix on each route's name.
- It's still DRY, because they all extend a base class.

At the same time, I could see no reason this needed to be "interfaced", so all of the classes are concrete.

Goes a long way to fixing #123 - still just a few places left remaining with hardcoded URLs.
2015-10-02 17:35:29 +09:30
js Fix scrubber dragging division by zero 2015-09-29 17:46:05 +09:30
less Use correct method for notification drawer on mobile 2015-09-29 01:28:47 +02:00
migrations Allow discussions to be hidden and restored 2015-09-22 17:48:21 +09:30
public/fonts Update to FontAwesome 4.4.0 2015-09-22 17:11:51 +09:30
scripts Add asset compilation script 2015-10-02 17:23:08 +09:30
src Add multiple UrlGenerator classes for forum/api/admin 2015-10-02 17:35:29 +09:30
stubs Add migration generator 2015-09-17 12:16:38 +09:30
tests Added tests for admin login/cookie checks 2015-09-28 16:02:37 +01:00
views Add multiple UrlGenerator classes for forum/api/admin 2015-10-02 17:35:29 +09:30
.editorconfig Clean up editorconfig, eslint, npm dependencies 2015-09-04 12:11:34 +09:30
.eslintignore Add JavaScript eslint config 2015-07-05 21:25:09 +09:30
.eslintrc Clean up editorconfig, eslint, npm dependencies 2015-09-04 12:11:34 +09:30
.gitattributes Include the extension stub's .gitignore file 2015-08-29 18:29:33 +09:30
.gitignore Added some tests for the database setting repository 2015-09-28 15:34:32 +01:00
.php_cs Add header comment; PSR-2 fixes; remove seeders 2015-08-26 16:56:32 +09:30
.travis.yml Fix last commit 2015-08-30 15:02:48 +02:00
CHANGELOG.md Update changelog for bundled extensions 2015-09-22 18:20:32 +09:30
composer.json Added zend-stragility (missing), removed some redundant code. 2015-09-28 15:59:07 +01:00
composer.lock Added zend-stragility (missing), removed some redundant code. 2015-09-28 15:59:07 +01:00
CONTRIBUTING.md Add CONTRIBUTING 2015-08-29 18:29:19 +09:30
LICENSE Update links and remove license file extension 2015-08-27 19:56:37 +09:30
README.md Update links and remove license file extension 2015-08-27 19:56:37 +09:30

Flarum Core

This repository contains the core code of Flarum. If you want to install Flarum, visit the main Flarum repository.

Contributing

Interested in contributing to Flarum? Please read the Contributing docs to learn how you can help.