Git Product home page Git Product logo

Comments (5)

rombat avatar rombat commented on June 1, 2024

That would be great! I'd like to use this package for Laravel 4.2 actually.

from seotools.

vinicius73 avatar vinicius73 commented on June 1, 2024

@rombat you can use https://github.com/vinicius73/SeoTools

from seotools.

edbizarro avatar edbizarro commented on June 1, 2024

Quando finalizarmos os testes vou pra essa :D

from seotools.

jakemitchellxyz avatar jakemitchellxyz commented on June 1, 2024

All you would have to do is remove all of the laravel helper functions (like array_forget() and array_get()) -- or better yet, include those functions in your own helpers.php file and include them via composer.json like:

"files": [
    "src/resources/helpers.php"
]

but once all of the helper functions are taken care of, the package is already agnostic. Someone not using Laravel could simply not register the service provider or alias, and use:

<?php
use Artesaos\SEOTools\SEOTools as SEO;

class SomeClass
{
    public function generateView()
    {
        SEO::setTitle('Home')->setDescription('Welcome to my website!');
        echo SEO::generate();
    }
}

obviously, that's an odd example, but it shows that a user can already use the package without Laravel. This is because the only thing Laravel is used for is setting up the Aliases and config (I am remove the config in my next pull, so if that is accepted, you won't have to worry about the config)

from seotools.

jakemitchellxyz avatar jakemitchellxyz commented on June 1, 2024

^^ As a matter of fact, someone using Laravel can even use the package without the Service Provider (once the config is gone)

from seotools.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.