What standard is SystemJS implementing? - systemjs

I heard that SystemJS implements a web standard. Does anyone know which standard it implements?
I assume when this web standard is implemented in browsers SystemJS will no longer be necessary. When is this likely to happen?
Or is my understanding wrong?

SystemJS implements roughly what the WHATWG Loader spec proposes, however there are some ongoing discussions, some of which were implemented in SystemJS albeit not being in the WHATWG spec. Currently, there is no finalized specification of what a module loading system should look like, but most browsers are currently working on something which looks quite similar and is even somewhat compatible.
Currently, <script type="module"> is what most browsers are working on. Chromium/Chrome scheduled the release for version 61, the Firefox developers also seem to work on it, and I believe Safari already shipped it. The main issue currently appears to be that some thing were not properly specified up front, meaning that they cannot just implement what the spec says, but have to improve the spec while implementing (see the linked tickets and associated tickets for details).
Additional ongoing specification work can be found inside the ECMAScript Harmony modules wiki page.

Related

Are there viable usecases for using standalone PHP scripts in a TYPO3 site?

I just came across this question How can I use a PHP script in typo3 v9?
and for me more interesting is right now - should you even do it and what are the possible usecases?
The reason I am asking: I am currently useing standalone legacy PHP scripts on a site. Not happily, as I had always intended to migrate this to an extension or deprecate it, but as is often the case - the PHP scripts may long outlive PHP itself ;-)
Consider you have some functionality, which you want to integrate in your website (as content inside the existing theme) which uses no specific TYPO3 functionality. Are there reasonable usecases to do this as PHP script without creating an extension? This answer suggests that it was possible but has been discouraged.
What are the pros / cons? Is this not recommended? Why? ...
TYPO3 >= 9.
Web Content Management is quite an old discipline and proably most requirements are known and years old. TYPO3 has adapted its architecture over the years to be more safe, more easy, more secure and to easily expand functionality. Thus, the idea of adding a plain PHP script instead of using the (omnipotent) API and extension library to include functionality means skipping the offered ideas of functionality, security and maintainability.
Nevertheless, adding functionality which is like a custom PHP script is easy, as the overhead to adapt a "spaghetti code php script" into the TYPO3 API is marginal (e.g. "put it in an extension", use PSR-0, with namespaces classes register the function with a ext_localconf.php line) and would easily improve the implementation (e.g. allowing a Command in backend-context as well as CLI, or adapting a Fluid/TypoScript wrapper depending on context Web-Frontend vs PDF).
So the basic overhead is not implementation time, but having a bootstrap extension skeleton (which exists) and the necessary API knowledge (which should exist for integrators). So "quick and dirty" isn't really a valid reason.
Basically it IMHO boils down to NIH syndrome, which shouldn't need to be supported at all.
So only con's here.

Future of mirrors in Dart

I am developing an app in Dart and I plan to support dynamically loaded plugins. I can't do this in mirrors as it does no support instantiating classes from external sources, listing classes from external files etc. Do you plan to extend mirrors to support java like reflections?
Thank you, Skoky.
It was discussed several times but I think it is not decided. What was mentioned as argument against this feature is security which is taken very seriously especially in the browser but of course there are advantages and not having this feature limits the possibilties of Dart.
What you can currently do is launching additional isolates from external code files. This is currently cumbersome in the browser because an isolate in the browser doesn't provide access to not only the DOM but any browser API which is extremely limiting. But as I understand there are improvements planned or maybe already work in progress.

Scala web frameworks' security

I am choosing a Scala web framework. Among frameworks I am considering are Play, Scalatra and Lift. In the project I am preparing for, security is important. However, web security is a blurry subject for me, and I would like my framework to handle it to a reasonable extent. I seem to be drawn to Play.
I am not asking what is the most secure framework (according to ads – Lift), but, rather, do Scala frameworks handle security for me, and how do they compare in that respect? I don't want to solely rely on my knowledge to make the web-app secure.
I'd vote for Liftweb http://seventhings.liftweb.net/security
The major difference to other frameworks (and especially to java's, like Spring) is what one may call "default behavior". For example, while coding, you can forget to "escape", some html attribute. In a bad framework you'll get errors with corrupt html and security holes. In a good framework you'll have double-escape or an error.
A full list of examples can actually be read in link. What personally I love Lift for is it's statefulness, Scala bindings to HTML like
"#myHtmlNode li div [onclick]" #> ajaxInvoke(...scala code here...)
In the code above, you'll be 100% sure that no one will have access to the contents of ajaxInvoke except for those users you sent the page yourself. And separation of the logic and the view is a relief, of course.
To answer my own question, I have to learn this stuff, no one is going to do it for me. There's OWASP cheatsheets; and also OWASP Enterprise Security API or ESAPI. ESAPI looks promising, though I haven't used it yet.

options for producing audio with GWT

What options are there for producing audio in a GWT app? I'm thinking of making a simple game, but I'm disappointed to see that there's still not much progress on audio support directly in GWT (yes, I realize that's largely due to lack of underlying browser support; looking forward to HTML5!)
This blog post says that "audio support in GWT is rapidly evolving", yet I don't see updates in over a year, at least not at that site. It seems these are the available options:
GWT Voices
GWT SoundManager
GWT Sound
GWT Incubator (all of the audio APIs seem deprecated here)
I believe most of these (all of them?) rely on Flash to produce audio. I'm most inclined to go with the GWT Incubator, as that's where features slated for inclusion in GWT get started, but I've no real recommendations to go on. I would appreciate hearing about your experiences with any of these libraries, thanks.
GWT Voices is written by Fred Sauer. He seems to be very closely affiliated with GWT. I've used his drag and drop code before, and found it quite well documented and frequently updated. Also, he seems responsive to questions in the forum. (I have no affiliation!)
I don't know anything about the others.
Most of the aforementioned SoundManager2 wrappers are dated and no longer supported. Gwt Voices is a good project, but lacks a lot of the functionality that is provided by a mature and proven solution like SoundManager2.
Check out this newer one called gwt-soundmanager2. It's a fork from Jeffery Miller's gwt-sound project. https://github.com/rcaloras/gwt-soundmanager2
(I created it, happy to answer questions or add additional features)

Is there a scala version of Python's Mechanize?

I have used mechanize in Python with great success. However, I am trying to learn Scala. I have an IRC bot that I would like to add some features to, mostly having to do with screen scraping web pages from our corporate intranet. That requires being redirected to a corp-wide login page, then going to the destination, then having to possibly submit another login.
Does anyone know of something that I can use from Scala to get this sort of functionality?
I don't know any Scala effort of similar functionality. Pending answers to the contrary, I advise you to look for Java libraries of similar functionality.
The closest Java libraries I can think of are browser drivers. The most well-known are Selenium and WebDriver. The latter also offers an in-process mode.
Since Selenium's API isn't all that pleasent to use, a couple of projects sprung-up with DSLish façades: Selenium DSL and Selenium Inspector.
A caveat is that they are all oriented towards testing of web application, so they might be lacking in features that attend your case.