Tired of Guessing Together SAPUI5 XML Views? Start Using UI5 Schemas Now!
TL;DR
$ npm install -g ui5-schemas $ ui5-schemas
What is it?
UI5 Schemas allows you to develop SAPUI5/OpenUI5 XML Views at a maximum convenience. It downloads, upgrades and sets up SAPUI5/OpenUI5 XML schemas for a better development experience in your favorite IDE (if it is WebStorm ;).
Why should I use it?
Don’t get me wrong: I like using SAP Web IDE for certain tasks like project creation from templates, WYSIWYG view editing, extensibility, mock data generation asf. But for doing the real coding work I want to use an environment that gives me maximum support and control. Not to even mention performance… Unfortunately SAP leaves you with no real choice besides SAP Web IDE since the SAPUI5 Tools for Eclipse is suboptimal at best…
My IDE of choice for web development definitely is WebStorm. And ever since I am developing SAPUI5 in WebStorm I try to optimize the development experience. One of the first and easiest steps was to extract the SAPUI5 schemas from the Eclipse Tools and use them in WebStorm as described earlier by SAP Mentor Robin van het Hof here. That already gives you a nice speed up while developing XMLViews and Fragments esp. when coming from zero support.
Anyways doing this is quite a bit of work… Besides that the schemas are not covering the whole story of XML views and fragments you will have to redo all of this when switching SAPUI5 versions. And that is were UI5 Schemas steps in:
What it does?
- downloads all libraries XML schemas for a certain SAPUI5 or OpenUI5 version and stores it in a temporary folder in your project
- applies some fixes on the schemas e.g. adding ‘class’ or ‘controllerName’ as valid attributes
- auto-registers the schemas with your project if you are using a JetBrains IDE (.idea folder exists; restart might be necessary).
And you get all of that by this two little lines:
$ npm install -g ui5-schemas $ ui5-schemas
With npm5 things get even easier:
$ npx ui5-schemas
Disclaimer
UI5 Schemas is released in a development version for now. Please let me know of any issues on github and I will try to improve.
What do you think?
Please let me know what you think of this tool. What development setup do you use out there and how do you improve your SAPUI5 development experience outside of SAP Web IDE? Feel free to suggest features and improvements in the github repository or even contribute. I can’t wait for your feedback!
If you like what you see I appreciate your support. Spread the word, star the repository or do whatever you do to have more people benefit from this little helper.
BR
Chris
Hi Christian,
Brilliant! This makes setting up your project much more easier! Using multiple versions of UI5 is now a breeze
Two questions:
Awesome work!
Hi Robin,
thanks again. Glad you like it!
I’ve just launched my website http://ui5experts.com and still have had some issues with 1&1 Managed Hosting which should now be fixed!
A similar module for JS is planned but I don’t have a schedule yet
BR
Chris
Great work! I am confident you eased life of UI5 developers a lot 🙂
I think this would be also a valuable addition to the Related Projects section on OpenUI5.org. Ever considered to contribute this to that page? I would even vote for highlighting it there 😉
Hi Margot,
didn't know that page yet 🙂 Contributing there is definitely a great idea. Will do that soon. Thanks for the hint!
BR
Chris
Done: https://github.com/SAP/openui5/pull/1643
Waiting for reactions 🙂
Great! It might take till next week as most folks are on vacation allowing to merge your request.
well done! excellent blog and share
Awesome work Christian.
Hi Christian, great work! I`m planning do use WebStorm soon.
Hi Christian,
I'm using WebStorm and it's great to have this 😉
Appreciate it!!
Thanks.