TMS Web Core

Yesterday, it has been a wonderful and symbolic day. It was Delphi’s birthday, Valentines Day and after weeks of rainy weather the sun was shining in North-Rhine-Westphalia where I live. 🙂

And something else happened: TMS Software announced TMS Web Core, the new web platform framework from TMS Software.

Why do I blog about this? There are two reasons: On the one hand it is a fantastic web framework and on the other hand I was allowed to work together with others on this framework. It was a wonderful experience to see how this project grew and grew. And I have to say that after 22 years of Delphi projects I haven’t worked in such a great team before!

But let’s come back to the framework itself. What exactly is TMS Web Core? Well, it is not only a web framework, it is a logical extension of RAD Studio.

Let me explain this step by step. Currently RAD Studio supports many platforms like Windows, MacOS, iOS, Android and Linux but not directly the Web. There are some extensions but not really the Web platform.

But with TMS Web Core things have changed. Delphi now supports a further platform, the Web. And with the Web I really mean modern HTML5 applications.

How could this be done?  HTML5 Web applications are not written in the Pascal language. They normally need HTML5 and JavaScript. That’s why some solutions offer Delphi components that produce JavaScript in the background, others paint some good old windows into the HTML5 canvas, but real HTML5 applications are written in JavaScript and not in Pascal.

Well, the trick is that TMS Web Core has a Pascal to JavaScript compiler. This means that you can write Pascal or Delphi code and then this code will be compiled to real JavaScript.

Okay, many of you now will ask why shouldn’t I write JavaScript directly? Why do I need Pascal? But there are three main reasons: I would like to use the full power of Delphi with all its wonderful features, platforms and components, I would like to reuse all my existing Delphi code and I simply like Pascal.

Reuse existing code, what does it mean? I know many software companies which have written over the years a huge code basis and simply don’t want to rewrite the code in another language. And if they would they would have to maintain at least for a while two languages. And we all know that this could be a very difficult issue that could collapse a whole company.

In short words, the integrated Pascal To JavaScript compiler has a huge compatibility to the Delphi compiler so that much of the Delphi code can be compiled to JavaScript. Its is clear that there are statements that cannot be compiled but believe me the level of compatibility is very high.

But what about components? Is it possible to have components that work with normal Delphi and TMS Web Core? I can simply say yes! There are the standard components like Buttons, Labels and Edits but there are also the FNC Components from TMS Software.

Just to give you a short overview: The FNC Components are the so called Framework Neutral Components. They compile for VCL, FMX and LCL. For all that are not familiar with LCL, it is a window framework for Lazarus, the open source pendant to Delphi.

The FNC components already existed before TMS Web Core. They offer for example Grids, TreeViews, InplaceEditors and much more and work for all platforms that Delphi and Lazarus support. This means that e.g. a FNC TreeView compiles under a normal VCL Win32 applications and also under a FMX iOS app! As I heard for the first time about this I thought that this is impossible but what should I say, it simply does work!

And now these FNC components also work in a HTML5 JavaScript website! And they have nearly the same look and feel as under other platforms. Here you can see some live examples, it is incredible!

Most of the Delphi applications that I have written in the past needed to connect to web servers. They needed to connect to databases or web services via REST or SOAP. There are also some great frameworks around which allows this in a very easy way. Some are already integrated into Delphi, others can be bought as Third-Party-Components.

One of the frameworks is TMS XData. And now as we know about the FNC components it doesn’t surprise that TMS XData also compiles for the Web! This means that you can put some TDataSet descendants on a WebForm and can write data-sensitive code like in every Delphi application!

I already explained so many things but there is one point I really have to mention: As a Delphi Developer I normally don’t like to design websites. This means that Web Designers can do this job much better than me but there is another trick: You can go to a web designer, ask him to create some wonderful websites and then you can connect your TMS Web Core form to an HTML page. You only have link your components to the existing HTML controls.

TMS Software explains this feature in the following way: “Yes, other than using the Delphi IDE form designer for WYSIWYG design of your web pages, you can create pages using HTML template files and using CSS. You can easily link UI HTML elements in the HTML page to controls on the Delphi IDE form designer and use the IDE just for creating the inter-UI control logic & UI control to server logic.

Certainly it is possible to compile a develop version of your code so that you can full debug your application in the browser.

I can mention so many other features: Components for showing Google Maps or YouTube, embedding jQuery…

For me, there were two very important milestones in the 23 year old history of Delphi: It was the publishing of Delphi itself and then the introduction of FireMonkey so that Delphi could be opened for further platforms. And now on Delphi’s 23th birthday Delphi goes Web!

Many thanks to

Bart Holvoet
Bruno Fierens
Detlef Overbeek
Holger Flick
Masiha Zemarai
Mattias Gaertner
Michael Van Canneyt
Pieter Scheldeman
Sanjay Kanade
Wagner R. Landgraf

This entry was posted in C++-Builder, Delphi, FireMonkey, RAD Studio 10 Seattle, RAD Studio 10.1 Berlin, RAD Studio 10.2 Tokyo, RAD Studio XE8, TMS Software, TMS Web Core, Uncategorized. Bookmark the permalink.

15 Responses to TMS Web Core

  1. I’ve been using Delphi with the web for years, but specifically not with the RAD IDE. Delphi is very strong as a visual designer tool for desktop applications, but the setup marrying objects to the visual components provided to the user is a bad fit for the server-client relation between web-server and html-client and the request-response cycle required to make a dynamic website work.

    In the recent decade browser features and performance has enhanced enough to allow them to mimic local applications, but translating application designs to web-pages with haevy client-side logic, still don’t offer a clear path to the finely tuned mix of client-side and server-side structures a decent web-project needs to conduct its operations smoothly and securely.

    Delphi and its powerful and fast Pascal compiler, are very suitable for systems-development and server-side logic. So that’s what led me to create xxm. It serves as a common base between ISAPI, Apache http modules and HTTP.SYS. And also a simple direct HTTP server great for using with the Delphi debugger. Because of the speed of the compiler and its incremental building (DCU files), xxm allows you to develop and test by refreshing in the browser.

  2. Exciting times for Delphi developers! Quick question – does the cross-compiler support Generics?

     

    Steve

  3. Glenn Dufke says:

    Funny thing though, Smart Mobile Studio has done the same thing for 7 years now, transpiling Object Pascal to Javascript with a powerful RTL 🙂

  4. Pingback: TMS WebCore, hat damit schon jemand Erfahrungen ? - Delphi-PRAXiS

  5. Alexandre Machado says:

    “Delphi now supports a further platform, the Web”. Denying all other web frameworks for Delphi is not ignorance because I’m pretty sure you know other frameworks well, so I’m not sure how I read this statement…. Let me also say that this is the only web framework “for Delphi” that actually doesn’t use the best thing Delphi has: the compiler. So how does it actually make it a “Delphi” framework? You know, using just the Delphi IDE to render HTML and JS doesn’t exactly make it a Delphi framework. SMS does the same, but using a different transpiler and also IDE. Although it is an Object Pascal based IDE/Framework, it is not a Delphi framework either.

    • roman says:

      TMS Web Core uses the Delphi compiler for code completion, code insight and for compiling the so called Web Runner. You can have a look here (The video is in German but maybe you can see how it works): https://www.youtube.com/watch?v=mKxjHcZM9g0.

      The idea behind TMS Web Core was to integrate it into the IDE like the other non-windows platforms. In the next blob post (http://blog.kassebaum.eu/?p=656) I tried to explain it.

      BTW, as you know, I’m using your web framework with great success for another customer and I really like it.

  6. Bill says:

    Hi,

    is it possible to use websockets via these components?

  7. Michael says:

    Seems to be very slow on their web site, for example the planner, or is the server speed so slow ??

     

    Look here:

    http://www.tmssoftware.biz/tmsweb/demos/tmsweb_fncplanner/

  8. Kerry Neighbour says:

    When is this going to be released? I need a framework like this for a new project, but cannot wait too long.

    • roman says:

      If you have an All Access account you can join the current beta test. After the beta test we will ship. I guess this will happen within the next three months.

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.