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

Problem upgrading from Uniforms 1.31.1 to 2.1.0 #553

Closed
philipmjohnson opened this issue Jul 12, 2019 · 4 comments
Closed

Problem upgrading from Uniforms 1.31.1 to 2.1.0 #553

philipmjohnson opened this issue Jul 12, 2019 · 4 comments
Assignees
Labels
Type: Question Questions and other discussions

Comments

@philipmjohnson
Copy link

philipmjohnson commented Jul 12, 2019

Greetings, I am trying to update my sample Meteor application to Uniforms 2.1.0. I have an AddStuff page that works fine under Uniforms 1.31.1. The form code (available in the branch uniforms-1.31.1) looks like this:

https://github.com/ics-software-engineering/meteor-application-template-react/blob/uniforms-1.31.1/app/imports/ui/pages/AddStuff.jsx

And when it runs, it creates a page like this:

uniforms-1 31 1-form

After running the npm commands to update to Uniforms 2.1.0 (including the new bridge package for simple-schema2), I get the following error message:

uniforms-2 1 0-form

A branch containing my updated system is available here:

https://github.com/ics-software-engineering/meteor-application-template-react/tree/uniforms-2.1.0

I looked through the release notes and couldn't find figure out what I need to fix in my 1.31.1 code in order for it to work in 2.1.0.

Thanks for any help you can provide.

@radekmie radekmie self-assigned this Jul 12, 2019
@radekmie radekmie added the Type: Question Questions and other discussions label Jul 12, 2019
@radekmie
Copy link
Contributor

Hi @philipmjohnson. I cannot find any bridge imported in your project. Have you read 2.0.0 release note? Bridges were separated from the core and have to be imported separately.

@radekmie
Copy link
Contributor

It is installed but it also has to be imported in the project, via require or import.

@philipmjohnson
Copy link
Author

philipmjohnson commented Jul 12, 2019

Thanks for the help, I read but did not fully understand the release notes. Here's the line I needed to add to my code in order fix this issue (for future googlers):

https://github.com/ics-software-engineering/meteor-application-template-react/blob/uniforms-2.1.0/app/imports/api/stuff/stuff.js#L22

Note that I also had to npm add the bridge package and also import it at the top of the file.

@radekmie
Copy link
Contributor

Importing it without actually creating the bridge would be enough. Glad it's solved!

@Monteth Monteth added this to Closed in Open Source (migrated) Jun 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Question Questions and other discussions
Projects
Archived in project
Development

No branches or pull requests

2 participants