Coder Social home page Coder Social logo

Implementing showDialog? about stacked HOT 7 CLOSED

stacked-org avatar stacked-org commented on August 11, 2024
Implementing showDialog?

from stacked.

Comments (7)

FilledStacks avatar FilledStacks commented on August 11, 2024

The example is using injectable which you don't have to use. If you do you still have to run the builder to generate the service registration code.

Seems like you're mixing up some stuff here. provider_architecture is the exact same as this package there's just some extra functionality in here and name changes. So how ever you did it with Provider package you can do the same with this one. No need to use injectable if you don't want to.

from stacked.

mistyn8 avatar mistyn8 commented on August 11, 2024

So I'm brand new to this... apart from watching the tutorials...
So starting with stacked and the example in there.

I assumed that the example was now the best practise starting point.. so was simply trying to add a dialog using the dialog service already in there.

got stuck.. so then as it was intimated there wasn't any changes other than naming referred back to the provider_architecture example... which is as you say not using injectable.. or get so got a little confused. :-)

from stacked.

FilledStacks avatar FilledStacks commented on August 11, 2024

No the example is definitely not a best practice of any kind. It's simply examples of how to use the widgets in the package. This is not a good place to start. I would say you should watch this video which is where the architecture comes from and where the package comes from. Then you can follow along with my Firebase series to understand how to use provider_architecture.

Get_it or injectable, or get has nothing to do with the provider_architecture or stacked. Those are extra libraries we use for other parts of the architecture like navigation and showing dialogs. If you don't know how to use the DialogService you can watch my video on it, the video is a bit out dated but you could figure out if you actually want to use it like that. I use get for the dialog service completely now.

I'd say if you go through my web series or my firebase series you'll see how the provider_architecture package is used. Then you install stacked and rename the classes since it's the same.

from stacked.

mistyn8 avatar mistyn8 commented on August 11, 2024

confused even more now then.. so the example folder in stacked which includes a dialog_service.dart isn't usable?
ps just tried the build from injectable and it added the dialog_service in.. but still same error shows when clicking the button I'd added the showDialog too :-)

But ok I will revert to example(s) from provider_architecture that don't use get/injectable and just as you say refactor to stacked.
(though get and injectable look good!! for offsetting more CRUD)

thanks kindly for you words of wisdom. :-)

from stacked.

FilledStacks avatar FilledStacks commented on August 11, 2024

The dialog service is usable. The key for get hasn't been set in the material app. You can set it and run the builder and it should work fine. But it's not an example of how to build an entire app with it.

Also the examples are copied from provider_architecture so you'll see the same code apart from the added new functionality.

from stacked.

mistyn8 avatar mistyn8 commented on August 11, 2024

You beat me to it,,, Was just about to post.. navigatorKey: Get.key, needed in MyApp after reading the get instructions... ;-) and a rebuild for injectable.

Are we talking about the same example here?

https://github.com/FilledStacks/stacked/tree/master/example/lib
vs
https://github.com/FilledStacks/provider_architecture/tree/master/example/lib

they aren't similar in a few ways, structure, no dialog_manager, services? enough to confuse me anyways...

Thanks again for entertaining and responding to my queries.

from stacked.

FilledStacks avatar FilledStacks commented on August 11, 2024

You're very welcome :) Happy to shed any light. The example folder structure is a bit different but I copied the view files as is with their viewmodels for the examples and just updated the naming.

I'm busy with the first videos written tutorial now. I'm hoping I can release it today. It's 8:40 AM here 26 April. I think I should be able to do the package updates, write a written tutorial, record and edit a video and upload it in 12 hours. Otherwise the video has to wait until next week :)

from stacked.

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.