Comments (6)
Hi
First category fails because you cannot combine prefix and explode as of RFC6570 Section 2.4
Second category is currently discussed here: #27 .
I hope that helped
Hannes
from uritemplate-test.
Thanks, @hannesg
It did :)
It looks like there's only the empty_list question in pull/21 that's left for a 100% PEG implementation in JS for URI templates.
from uritemplate-test.
Hi Andrej,
of course for a 100% compliant implementation you could use my https://github.com/fxa/uritemplate-js https://github.com/fxa/uritemplate-js ;-)
But if you prefer to write your own, please make a performance diff check and inform me!
Franz
Von: Andrei Neculau [mailto:[email protected]]
Gesendet: Mittwoch, 22. Mai 2013 11:06
An: uri-templates/uritemplate-test
Betreff: Re: [uritemplate-test] Prefix values & combinations (#29)
Thanks, @hannesg https://github.com/hannesg
It did :)
It looks like there's only the empty_list question in pull/21 that's left for a 100% PEG implementation in JS for URI templates.
—
Reply to this email directly or view it on GitHub #29 (comment) . https://github.com/notifications/beacon/z007K-oJ-ZnzAnsfdzRoGU3idJwQAUchtLtz949U6jooNrbTFZwvD9oTLvqRiBBl.gif
from uritemplate-test.
@fxa :) yes, I know about your lib as well. Thank you
I prefered not to write my own, but to improve @hannesg implementation because
- it uses PEG, and thanks to apiary.io I love PEGs
- I'm not particularly fond of the process you use (dependencies, jake-building instead of requirejs optimizer, etc)
- a subjective reason: the code was easier to follow (may have been also because it's in coffee-script)
Don't take this at heart, but that's the honest truth as to my drive.
FYI currently the implementation is 99% compatible with uritemplate-tests, and I'm awaiting some answers in #21 (comment) regarding the failing testcases -- maybe you have some input?
I wouldn't want to just follow blindly the testcases, and bend the lib around them. I might as well learn/challenge smth on the way. No software and no test is perfect.
PS: performance is important, but long-term it's even more important to have readable code. Even so - quick comparisons of running all tests (227) at once give real 0m0.707s;user 0m0.225s;sys 0m0.043s
. Come back with your timings :)
from uritemplate-test.
Of course I don’t take this at heart ;-)
I just don’t like coffee script, because it is the attempt to build a language within another language,
Here rebuild ruby with javascript.
And that did not work with groovy and the guava lib.
If you want to program with ruby, just take ruby.
If you want to program functional in the jvm, take scala.
But don’t use a hybrid.
But that is just my 2cents.
For the moment I am implementing some crypto javascript,
So I am very focused to performance ;-)
It is not funny to see, when chrome needs just 80ms and IE8 on the same machine more than 6 seconds.
Franz
Von: Andrei Neculau [mailto:[email protected]]
Gesendet: Mittwoch, 22. Mai 2013 16:47
An: uri-templates/uritemplate-test
Cc: Franz X Antesberger
Betreff: Re: [uritemplate-test] Prefix values & combinations (#29)
@fxa https://github.com/fxa :) yes, I know about your lib as well. Thank you
I prefered not to write my own, but to improve @hannesg https://github.com/hannesg implementation because
- it uses PEG, and thanks to apiary.io I love PEGs
- I'm not particularly fond of the process you use (dependencies, jake-building instead of requirejs optimizer, etc)
- a subjective reason: the code was easier to follow (may have been also because it's in coffee-script)
Don't take this at heart, but that's the honest truth as to my drive.
FYI currently the implementation is 99% compatible with uritemplate-tests, and I'm awaiting some answers in #21 #21 (comment) regarding the failing testcases -- maybe you have some input?
I wouldn't want to just follow blindly the testcases, and bend the lib around them. I might as well learn/challenge smth on the way. No software and no test is perfect.
PS: performance is important, but long-term it's even more important to have readable code. Even so - quick comparisons of running all tests (227) at once give real 0m0.707s;user 0m0.225s;sys 0m0.043s. Come back with your timings :)
—
Reply to this email directly or view it on GitHub #29 (comment) . https://github.com/notifications/beacon/z007K-oJ-ZnzAnsfdzRoGU3idJwQAUchtLtz949U6jooNrbTFZwvD9oTLvqRiBBl.gif
from uritemplate-test.
errata: "but to improve __ @grncdr __ implementation because"
from uritemplate-test.
Related Issues (20)
- Changes to spec-examples-by-section are missing HOT 2
- Strange Variables HOT 1
- Incorrect test case in negative tests? "/vars/:var" , false HOT 8
- Reasoning behind some expansion tests? And probable errors in test files HOT 5
- Missing test(s) from "spec-examples.json"
- "Reversible" sub-set of tests? HOT 3
- I think Form-Style Query expansion for string value is incorrect. HOT 1
- regex under construction HOT 2
- Missing tests for +/# with pct-encoded characters
- Help understanding some negative tests HOT 1
- spec-examples.json is missing cases HOT 2
- How should hierarchical names (`.` separated) be expanded HOT 6
- Lists should be ordered? HOT 6
- Declare license in a machine-readable way that Github understands HOT 1
- PCT encoded varname for form style query expansion with list value
- Single Quote in URI Templates is disallowed but reserved in URLs. HOT 15
- Tests with $ sign are missing HOT 1
- Tests for combination of `+` operator, percent-encoded value, and prefix modifier are missing HOT 1
- "negative-tests.json" Too Strict ("{keys:1}", "{+keys:1}") HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from uritemplate-test.