Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
lucono
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
5 ms
·
1.
▲
by
lucono
9y ago
> The idea is that variable is something you will rarely type This, precisely. I feel Ceylon uses more sensible defaults all around, like also having non-public methods/properties by default unless explicitly declared public. I use
2.
▲
Xtypejs: Full-featured, powerful and elegant data validation for JavaScript Apps
(xtype.js.org)
1 points
by
lucono
11y ago
|
0 comments
3.
▲
by
lucono
11y ago
There is a non-open-source JavaScript decorator library using this. It has many (real) examples, but the one that first comes to mind is its use of the xtype.is API method ( http://xtype.js.org/api/is ) to perform runtim
4.
▲
by
lucono
11y ago
Example of using xtypejs: Go from this: function searchEmployees(value) { if (typeof value === 'string') { if (value.trim().length > 1) { return EmployeeDB.searchByName(value);
5.
▲
by
lucono
11y ago
Thanks to lots of great community feedback and input, xtypejs now has a home at [ http://xtype.js.org](http://xtype.js.org) , with great documentation, user guide, and lots of examples.
6.
▲
Xtypejs: data validation for JavaScript Apps
(xtype.js.org)
17 points
by
lucono
11y ago
|
6 comments
7.
▲
Show HN: Xtype.js.org – 40 efficient data-validating pseudo-types for JavaScript
(xtype.js.org)
1 points
by
lucono
11y ago
|
0 comments
8.
▲
by
lucono
11y ago
Constructive criticism is very welcome. I updated the docs to better highlight the compact naming scheme switch. Definitely appreciate the feedback.
9.
▲
by
lucono
11y ago
Thanks. I developed and used it as a utility in a bigger library that worked heavily with types, but later exported it to its own project so I could share it, after I realized how useful it was, even stand-alone. It is very highly optimized
10.
▲
by
lucono
11y ago
There is no pseudo-code in the documentation. All of the documentation code executes as documented. The library works with type names in two naming modes - default and compact. The default name scheme uses the full type names, such as '
11.
▲
Fixing the Ugly JavaScript and ES6 NaN Problem
(lucono.com)
2 points
by
lucono
11y ago
|
0 comments
12.
▲
Show HN: Xtypejs – Efficient data-validating pseudo types for JavaScript
(github.com)
10 points
by
lucono
11y ago
|
6 comments