1
0
mirror of https://github.com/flarum/core.git synced 2025-07-31 13:40:20 +02:00

Refactor Flarum\Web and Flarum\Admin

- In order to be consistent with the Ember/LESS naming scheme, renamed
Flarum\Web to Flarum\Forum.
- Moved common classes into Flarum\Support so that Flarum\Admin doesn’t
depend on Flarum\Forum. Also moved Actor into Flarum\Support as it
doesn’t belong in the domain.
This commit is contained in:
Toby Zerner
2015-03-30 16:17:04 +10:30
parent fc4da97b80
commit 6898e0acbb
31 changed files with 94 additions and 88 deletions

View File

@@ -0,0 +1,45 @@
<?php namespace Flarum\Forum;
use Illuminate\Support\ServiceProvider;
use Flarum\Support\AssetManager;
class ForumServiceProvider extends ServiceProvider
{
/**
* Bootstrap the application events.
*
* @return void
*/
public function boot()
{
$root = __DIR__.'/../..';
$this->loadViewsFrom($root.'/views', 'flarum.forum');
$assetManager = $this->app['flarum.forum.assetManager'];
$assetManager->addFile([
$root.'/ember/forum/dist/assets/vendor.js',
$root.'/ember/forum/dist/assets/flarum-forum.js',
$root.'/less/forum/app.less'
]);
$this->publishes([
$root.'/public/fonts' => public_path('flarum/fonts')
]);
include __DIR__.'/routes.php';
}
/**
* Register the service provider.
*
* @return void
*/
public function register()
{
$this->app['flarum.forum.assetManager'] = $this->app->share(function ($app) {
return new AssetManager($app['files'], $app['path.public'].'/flarum', 'forum');
});
}
}