Giter VIP home page Giter VIP logo

Comments (4)

driesvints avatar driesvints commented on May 24, 2024 1

It's because of the aliasing. That indeed doesn't seem to be working. I can use it when I use the full namespace:

$ a tinker
Psy Shell v0.10.8 (PHP 8.0.9 — cli) by Justin Hileman
>>> app()->make(App\Services\FooService::class)
=> App\Services\FooService {#3431
     +a: 1,
   }
>>>

I looked into this a bit but have no idea why it doesn't work for the alias. Appreciating any help with figuring this out.

from tinker.

driesvints avatar driesvints commented on May 24, 2024

Hey Yamut. Since we only received one bug report for this I'm going to close this as we don't want to put in the work/time into this ourselves right now and we don't consider this a very priority issue. Should we receive more reports for this we can have a look. Otherwise we'd appreciate PR's. Thanks

from tinker.

Radiergummi avatar Radiergummi commented on May 24, 2024

Hi there, unfortunately I just hit the exact same issue - it's not a major blocker, but definitely annoying.

The fact that it works with the FQCN is very relieving though! Thanks for that.

from tinker.

lk77 avatar lk77 commented on May 24, 2024

Hi,

i have the same issue,

when doing app(MyClass::class) or even app(FQCNofMyClass::class),
the subclasses passed into the constructor of the main class are not the correct one,
they should be the one from the app()->bind() but it's not the case in tinker for some reason

from tinker.

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.