Skip to content

stevenmaguire/elvish-ipsum

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
src
 
 
 
 
 
 
 
 
 
 

Elvish Ipsum Generator

Latest Version Software License Build Status Coverage Status Quality Score Total Downloads

tl;dr

Add random elvish words to your laravel application.

Required setup

composer require stevenmaguire/elvish-ipsum

In your config/app.php add 'Stevenmaguire\ElvishIpsum\Provider' to the end of the $providers array

'providers' => array(

    'Illuminate\Foundation\Providers\ArtisanServiceProvider',
    'Illuminate\Auth\AuthServiceProvider',
    ...
    'Stevenmaguire\ElvishIpsum\Provider',

),

Also in your config/app.php add 'Elvish' => 'Stevenmaguire\ElvishIpsum\ElvishFacade' to the end of the $aliases array

'aliases' => array(

    'App'             => 'Illuminate\Support\Facades\App',
    'Artisan'         => 'Illuminate\Support\Facades\Artisan',
    'Auth'            => 'Illuminate\Support\Facades\Auth',
    ...
    'Elvish'          => 'Stevenmaguire\ElvishIpsum\ElvishFacade',

),

Usage

When you want to include elvish text in your project, simply call one of the following methods:

    $words = Elvish::getWords(10);
    $sentences = Elvish::getSentences(6);
    $paragraphs = Elvish::getParagraphs(2);

Originally crafted to support a project I demo'd at a Chicago Laravel Meetup

About

Add Elvish words, sentences, and paragraphs to your Laravel project

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages