Relative Content

Tag Archive for flutterprovider

Can access Provider using Nested Providers

I have a Flutter app that has a main localization provider, which is located at the root of my app. I then have a provider I want to provide only to the ‘registration’ route (which itself has a number of subroutes) since it handles all of the business logic and data associated with Registration. However, when I do this I get an error where I can’t use Provider.of because it says the provider was not provided by the context. What am I doing wrong? This seems like it should work from everything I have read. I have my code below, but I have omitted the all of the simple logic checks and such that are unrelated