Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecated code on lucid init:micro #36

Open
cweagans opened this issue Feb 8, 2022 · 5 comments
Open

Deprecated code on lucid init:micro #36

cweagans opened this issue Feb 8, 2022 · 5 comments

Comments

@cweagans
Copy link

cweagans commented Feb 8, 2022

PHP 8.1, Laravel 9

I just added Lucid to my project and ran lucid init:micro and got this:

Initializing Lucid Micro for Laravel 9.0.0

Created directories:
/app/Data
/app/Domains
/app/Features
/app/Operations
/app/Data/Models
/tests/Domains
/tests/Operations
PHP Deprecated:  str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /var/www/html/vendor/laravel/
framework/src/Illuminate/Support/Str.php on line 637

Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /var/www/html/vendor/laravel/frame
work/src/Illuminate/Support/Str.php on line 637

You're all set to build something awesome that scales!

Here are some examples to get you started:

You may wish to start with a feature
lucid make:feature LoginUser
will generate app/Features/LoginUserFeature.php

Or a job to do a single thing
lucid make:job GetUserByEmail User
will generate app/Domains/User/Jobs/GetUserByEmailJob.php

For more Job examples check out Lucid's built-in jobs:
- Lucid\Domains\Http\Jobs\RespondWithJsonJob
for consistent JSON structure responses.

- Lucid\Domains\Http\Jobs\RespondWithJsonErrorJob
for consistent JSON error responses.

- Lucid\Domains\Http\Jobs\RespondWithViewJob
basic view and data response functionality.

Finally you can group multiple jobs in an operation
lucid make:operation ProcessUserLogin
will generate app/Operations/ProcessUserLoginOperation.php

For more details, help yourself with the docs at https://docs.lucidarch.dev

Remember to enjoy the journey.
Cheers!
@jEstevezRod
Copy link

is it abandoned?

@Mulkave
Copy link
Member

Mulkave commented Apr 13, 2022

@jEstevezRod no, and way too far from being so 😄 just short on time these days.

@cweagans thanks for reporting! I will look into this sometime this week.

@metion
Copy link

metion commented Jul 28, 2022

Hello. When you will fix it? We will start to new project with lucid.
Bug in the Str.php. You can fix it like that

public static function studly($value)
    {
        return $value ? LaravelStr::studly($value) : value;
    }

public static function snake($value, $delimiter = '_')
    {
        return $value ? LaravelStr::snake($value, $delimiter) : value;
    }

@martio
Copy link

martio commented Dec 13, 2022

@Mulkave Will there be support for PHP 8.2 and Laravel 10?

@ksimenic
Copy link

Feel free to use my fork https://github.com/ksimenic/lucid. It has all optimizations for Laravel 10 and no more deprecated code in init:micro.

All you need to do is to add following in your composer.json

    "repositories": [
        {
            "type": "vcs",
            "url": "https://github.com/ksimenic/lucid"
        }
    ],

and then require

"lucidarch/lucid": "dev-latest"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants