Marc Bernard ๐Ÿš€ Profile picture
Apr 1 โ€ข 29 tweets โ€ข 10 min read
You can run #ABAP applications in your browser ๐Ÿคฏ

No #SAP system required โ—

Any questions, @SAP @SAPdevs @SAPcommunity โ“
Yeah, I thought so... You have your doubts ๐Ÿค” ๐Ÿ’ญ
We know. We surely must have a big server and an SAP Kernel ๐Ÿ–ฅ๏ธ
Well... no ๐Ÿšซ
Here's how it works ๐Ÿงต

TLDR: Our friend @LarsHvam has coded a #magic transpiler that takes #ABAP code as input and turns it into JavaScript. And that script runs in your browser. Viola!

There's a lot going on behind the scenes...
1.

#abaplint checks your code

There are 142 rules and you can use it for your open source projects, too

That by itself is impressive ๐Ÿ˜ฎ
2.

If your code is well, #abaplint creates a syntax tree ๐ŸŒณ which becomes the foundation for the next step

There's so much more it offers

Open the link in another window to check it out later

abaplint.org
3.

#ABAP isn't just "language". It's a platform that includes a lot of coded features (like libraries in other languages).

For example, running ABAP unit tests requires class cl_abap_unit_assert ๐Ÿงช

This is where #openabap comes into play

github.com/open-abap/openโ€ฆ
4.

The #transpiler puts all the pieces together:

ABAP > lint > js + open-abap > run ๐Ÿƒ
OK, still skeptical?

#AprilFools โ˜ ๏ธ
Why are you still here? ๐Ÿค”
I hear you

You want proof

Alright, grab a drink and let's give it a try, together ๐Ÿน
#Wordle anyone? ๐Ÿ’ฌ

My wife ๐Ÿ‘ฉ has a better average than me.
I need help ๐Ÿ†˜

@hugo_de_groot and his #ABAP Wordle Assistant to the rescue

It does wonders, #believeme

But it needs an SAP system...

github.com/hdegroot/zwordโ€ฆ
Let's see if we can make this run in our browser ๐Ÿ–ฅ๏ธ

No SAP system, I promise
5.

Ready? Start your engine ๐ŸŽ๏ธ

Open transpiler.abaplint.org
6.

ABAP on the left โ†

Transpiled JS in the middle

Output on the right โ†’

Greeted by a friendly "hello" ๐Ÿ‘‹
Nah, that's fake

#AprilFools ๐Ÿ’ฃ
I dare you to change the code ๐ŸŽฒ
See, I told you it works ๐Ÿ’ซ
Side note:

๐Ÿšง Seriously, this is mind blowing. Please consider that it's relatively new. Not everything is perfect and there are limits (i.e. no DDIC). Report bugs on GitHub. @LarsHvam will do his best to fix them. Or contribute yourself if you are able ๐Ÿšง
This will grow and be unbelievable, IMHO ๐Ÿš€
7.

Let's run an #ABAP app in the browser

Back to the Wordle Assistant

I adjusted it slightly to work in the transpiler. Still ๐Ÿ’ฏ ABAP

Grab the code from GitHub

wordle.marcf.be
8.

Clear the window on the left โ†

Paste the zwordle.abap code

Boom ๐Ÿ’ฅ

It already runs!
9.

Scroll to the end of the code

You find the method call and a few "letter" parameters

Take a Wordle after a guess or two ๐Ÿงฉ

Plug your black โฌ›, orange ๐ŸŸง, and green ๐ŸŸฉ letters into the parameters

Watch the results change on the right โ†’
10.

You will find the word with the highest probability to match on the top of the list ๐Ÿ“œ

Some words are pretty rare so I skip those

Picking something from the top 10 is the way to go ๐Ÿ”

#awesome
PRO Tip 1๏ธโƒฃ

To avoid the real-time updates after each keystroke, compose the method call with parameters in a separate editor.

Then cut & paste it into the browser.
PRO Tip 2๏ธโƒฃ

If you don't enter anything for a letter place, all letters except the black ones will be allowed.

Fine-tune a letter parameter by using 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' minus all black AND minus all orange letters that occurred in that place.
That's it!

We have a winner ๐Ÿ†

1100 lines of #ABAP code running in YOUR browser

Happy Weekend, Everyone ๐Ÿ๏ธ

#AprilGenius ๐Ÿง 
I hope you've found this thread entertaining ๐ŸŽˆ

Follow me @marcfbe for more

Like/Retweet the first tweet below if you can:

โ€ข โ€ข โ€ข

Missing some Tweet in this thread? You can try to force a refresh
ใ€€

Keep Current with Marc Bernard ๐Ÿš€

Marc Bernard ๐Ÿš€ Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us on Twitter!

:(