Live data from Hacker News

Introduction to HTML Components

blog.mecheye.net

41–50 of 151 posts

Re: Introduction to HTML Components

#41
post #38
post #20

Earlier quoted context omitted.

I was a big fan of XHTML and all related XML Components, but then politics won.

Yeah but having to switch to createElement, appendChild, insertBefore, createTextNode just because innerHTML was not allowed was a pain in the butt.

at this point i'm considering creating a backend framework that sends a grid of images and uses imagemaps for clicks.

with fast internet raster images shouldn't be a big issue.

Re: Introduction to HTML Components

#43
post #38

Earlier quoted context omitted.

Yeah but having to switch to createElement, appendChild, insertBefore, createTextNode just because innerHTML was not allowed was a pain in the butt.

at this point i'm considering creating a backend framework that sends a grid of images and uses imagemaps for clicks. with fast internet raster images shouldn't be a big issue.

Just use SVG/CSS with JavaScript events, that is the approach for the new FitBit SDK.

Re: Introduction to HTML Components

#44
post #10

Earlier quoted context omitted.

I really tried with Polymer (for the last few months) but it was particularly verbose. I remember implementing an " " tag, and thinking that this is so wild and "Out There" that I may simply never understand. Annoyingly, there is a whole "Hybrid" mode as well. So there is no distinction between V1 and V2. If you are confused,you go to the docs, they aren't giving you what you need, so you go to one of the sample elem…

Angular v1 or v2 though? :P

4 :P

Re: Introduction to HTML Components

#45
post #6

I used HTC a lot and waited for the other browsers to implement it. XBL came around but waited many years until it became web components. Great post!

All this talk of HTCs reminds me of HTAs: HTML Applications. https://msdn.microsoft.com/en-us/library/bb250409(v=vs.85).a... They behaved like a native app, with control over their native chrome, and without any browser sandboxing: their JavaScript (JScript) or VBScript could use COM components to access to the file-system and other features, including loading other binaries in-process. File-system access was through…

You can still do this, and in OSX too using MacGap (or writing a tiny webview wrapper yourself). The main reasons this is not widely done are incomplete device APIs, no control over browser versions/features - app might break at any moment for different subsets of users, and the lack of cross-platform compatibility. Electron actually solves most of those pain points despite the heft.

Re: Introduction to HTML Components

#47

Earlier quoted context omitted.

All this talk of HTCs reminds me of HTAs: HTML Applications. https://msdn.microsoft.com/en-us/library/bb250409(v=vs.85).a... They behaved like a native app, with control over their native chrome, and without any browser sandboxing: their JavaScript (JScript) or VBScript could use COM components to access to the file-system and other features, including loading other binaries in-process. File-system access was through…

You can still do this, and in OSX too using MacGap (or writing a tiny webview wrapper yourself). The main reasons this is not widely done are incomplete device APIs, no control over browser versions/features - app might break at any moment for different subsets of users, and the lack of cross-platform compatibility. Electron actually solves most of those pain points despite the heft.

Does the Cocoa WebView expose any kind of non-sandboxed COM-like API for system access? That was what made HTAs so useful.

Re: Introduction to HTML Components

#48
post #24

Earlier quoted context omitted.

All this talk of HTCs reminds me of HTAs: HTML Applications. https://msdn.microsoft.com/en-us/library/bb250409(v=vs.85).a... They behaved like a native app, with control over their native chrome, and without any browser sandboxing: their JavaScript (JScript) or VBScript could use COM components to access to the file-system and other features, including loading other binaries in-process. File-system access was through…

This! I love simplicity of electron but it is absurdly resource hungry.

I don't agree that Electron is simple. Electron runs a Node.js instance as a websever and application server in-proc, while also running Blink/WebKit for each frame instance. There's no consolidation going on, and I feel for a majority of Electron applications there's no need for the Node instance because all they're serving is an Angular app using the built-in `chrome.` APIs. What would be simple is if a script tag in a single HTML file could access the filesystem or Windows registry - but under Electron they can't.

Re: Introduction to HTML Components

#49
post #19

Personally, I think there's an important lesson here, and its the same lesson that polymer is learning as it stumbles around trying to convince people to use it. Most people don't actually derive much benefit from writing custom UI widget primitives. Certainly, that's a useful thing for a UI toolkit builder to be able to do, but tangibly, for most people, it's not actually useful. I don't have time to invest hours im…

I think that people that disregard Polymer fail to understand that Web Components are already here. They are fully supported on Chrome and Safari, and hopefully Firefox and EDGE will eventually catch up with them. And they have to, because Chrome and Safari own the mobile web. Polymer is transitioning to being a thin layer on top of what the browsers support, which basically means a Polyfill for Firefox and Edge, and…

> I think that people that disregard Polymer fail to understand that Web Components are already here.

No. Polymer is here. As Rob Dodson said, "Polymer is the jQuery of WebComponents".

No one in their right mind would even think about writing and using WebComponents in vanilla JS.

Hence we're coming back to the problem with WebComponents: they are a solution in search of a problem.

Re: Introduction to HTML Components

#50
I think the main problem with IE technology was the way Microsoft pushed it down our throats. The tech wasn't necessarily bad, but when the giant corporation pushes new features while not respecting/implementing the existing standards very few people support their efforts.

So as a result 96% hated the IE and the other 4% were using other browsers. No wonder nobody wanted to use the newest Microsoft only features.

Post reply on HN