-
Notifications
You must be signed in to change notification settings - Fork 177
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
Feature: migrate to angular 6 #295
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Hamza Hamidi <[email protected]>
Signed-off-by: Hamza Hamidi <[email protected]>
Signed-off-by: Hamza Hamidi <[email protected]>
Signed-off-by: Hamza Hamidi <[email protected]>
Signed-off-by: Hamza Hamidi <[email protected]>
Signed-off-by: Hamza Hamidi <[email protected]>
Signed-off-by: Hamza Hamidi <[email protected]>
Signed-off-by: Hamza Hamidi <[email protected]>
Signed-off-by: Hamza Hamidi <[email protected]>
For people who can't wait for this update to get merged here's a quick fix:
You may need to install @angular/flex manually: |
After downloading the code of the angular6 migration, what are the steps to build the lib locally and use it in my own projects ? |
@maher1991 If you want to add the library to your project, just run the commands above in the root of your project & then Then import JsonSchemaFormModule in your main application module, like this:
|
It works fine. Thanks |
Hello there, do you plan to merge this ? |
@Goopil
This project has not been actively contributed to since February 4th, 2018. Looking at contributors you see the four main committers have not made a change for quite some time. My advise is to follow shamoons' fork, whose author has stated he wants to dedicate his spare time to improving the project. |
Thanks for the advise. I will do just that. |
@hamzahamidi Yes i've seen it. What do you plan to do with your fork ? |
@Goopil I'm hoping it get merged in the main repo. We use this library in big projects, so we really need this update. In the mean time we're using my fork. |
@hamzahamidi we are in the same situtation. i hope it will be merged soon |
@hamzahamidi I really appreciate your work on providing us an Angular 6 build. Thanks a lot. When I use this build, I found using schema involving
After digging around for a while, I found the cause of the problem is this function in the JS file after build (line 5650 in
The problem is that the last function call
The last line of function The problem wasn't in the current master build. This is what looks like in the current build:
We can see that the function It seems like when we update to Angular 6, the library build process is messed up. I'm worried about this issue could potentially cause more bugs. I tried to find what configuration caused the exact problem, but I'm currently clueless. I'll continue finding the solution, @hamzahamidi I would really appreciate it if you or anyone else could help in solving this problem. |
@zuozhiw Thank you for your feedback. Can you provide me please with your json schema, browser, node & npm version to reproduce the error? Thank you again for your feedback. |
@hamzahamidi Thanks for the reply. Here's how to reproduce: Json Schema: {
"properties": {
"options": {
"type": "string",
"enum": [ "a", "b", "c"]
}
},
"type": "object"
} On the generated form, click option "b" or "c" in the drop down menu, then you can see the error in console. Versions: |
@zuozhiw In the meantime, try rewriting it in ES6 syntax:
Though honestly, that last call to |
This Repo also is compatible with Angular v6 & follows Angular v6 best practices for generating libraries. Edit:I transferred the Repo in my personal GitHub |
@hamzahamidi I've tested your new repo locally and it now works for the bug I encountered 👍 Thanks a lot. We are also upgrading to Angular 6 and you saved the build! A couple of things that I suggest:
|
@hamzahamidi Thank you very much, your version is working but unfortunately layouting not works for me. Generated form just ignore the layout json... :( And this is most important feature. Can you find some time to test it on your own? |
JFYI: @hamzahamidi doing great job with this version |
PR Type
What changes does this PR include (check all that apply)?
[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build process changes
[ ] Documentation changes
[ ] Other... please describe:
Related issue / current behavior
The library is currently incompatible with Angular v6 mainly due to some changes in RXJS v6, material Angular v6 & Angular v6
New behavior
Does this PR introduce a breaking change?
[ ] Yes
[x] No
Any other relevant information