Tern – Intelligent JavaScript editing
ternjs.net
ternjs.net
And I'd think that CodeMirror is the obvious thing to hook this into, for the rest of us as well.
In fact i have been an "texteditor-only" type in the past, but coding C# in Visual Studio has really been a revelation for me.
The fact that application X is "just a text editor" is not a justification for X having poor editing functions. In fact, you'd expect a specialized text editor to have better editing functions that an IDE, since an IDE can have other selling points, such as an integrated build system, a version manager, a profiler or a debugger, whereas an editor can only impress you solely by its usability for...well, editing.
Though ternjs's developer created CodeMirror, the platform would be agnostic of editor and could easily be ported to that.
Re the indiegogo campaign: I think you should consider adding an extra supporter tier between 25 USD and 1000 USD. The 200 USD tier of CoffeeScript Redux http://www.kickstarter.com/projects/michaelficarra/make-a-be... brought in over 20% of the total amount pledged.
As for CoffeeScript support -- the only major piece missing there is an error-tolerant CoffeeScript parser. Given that, one could simply run the CoffeeScript compiler over code, and analyze the output. There'd be some shuffling with source maps needed to translate source locations in the various representations of the code, but that's a solved problem. Well, and of course you might see some translation artifacts. The CS output code is semantically close to the input, but there are differences.
The closest I've seen to something that works well is IntelliJ IDEA 12, when working with ActionScript, Closure annotated JS (JsDoc'ed libraries), or by comparison, the Dart editor.
With IntelliJ 12, if you're looking at a library with enough JsDoc on functions, the type inferencing seems to be a lot more accurate. Find Usages, Go to Definition, code-assist, all seem to be more pleasurable to use.
I don't like Flash, but ActionScript3 in IntelliJ is as close to the Java/C#/et al experience you'll get with respect to accuracy of assist. Probably wouldn't hard to port this over to JSX or Typescript which have similar syntax.
Slightly related, I'm working on a feature where it distinguishes wild guesses from probably correct information by showing a different icon in the completion list.
And M-./find usages is very useful too, even when it is not perfect.
I pledged, and hope you will get enough funds together.
So when you have a function like: def foobarize(f): return f.something *2; then it will know what types f might have when foobarize is called. Now when you go back into the editor, it can give you a hint about it.
Other than that, it uses some type hints from docstrings (you can tell it type foo is YourClass and it will complete based on that) and light type guessing.
P.S. Works fine on Chromium Version 24.0.1312.56 Ubuntu 12.04 x64
I do wonder how it will compare to Eclipse Orion's JavaScript content assist which is using Esprima as parser.
http://contraptionsforprogramming.blogspot.nl/2012/02/better...
It compares very favorably. The Orion approach, as I understand it (I only did some quick messing around with scripted, am not an expert) is very local, whereas Tern tries to do whole-program analysis. This should allow it to pick up much more information.
The one exception is requirejs-style dependencies. Those, if you give Tern some information on where to look, it will resolve and automatically include. I'll do something similar for node.js-style require calls in the future.
I suppose you're not doing live type feedback? Given a test suite for the code being edited, that would seem like a natural thing to do.
Disclaimer: I liked it enough to buy a personal license :), but am not affiliated with the folks who make and sell it.
Repeated by reloading the page. Same result.
FireFox / MacOS.
[You'll need to hard-refresh to get the fixed code.]
Uncaught TypeError: Cannot set property 'curOrigin' of undefined (infer.js:489)
Looks interesting though!
Hopefully, that will happen. Sounds very cool though, as my IDE, sublime text, is rather underpowered in the intelligence department I'm afraid.
I could imagine it applying .tmLanguage scopes to words in the document, where you could colorize different variables according to type (I would opt for different background shades, myself). Then, mixed type colors (prompting you to click it and see what Tern says) when you can't know. Damn, that would be helpful.
> The funding goal is computed to allow me to work for three months at about half the income I make with my usual consulting work. (The other half is made up in the satisfaction of building the thing I want to build.) In addition, I'll spend some of it to engage a Vim expert to help me build the Vim plug-in in a way that fits the culture for that editor.
Definitely chipping in.
Very odd model... take your code.
Sure it might be a trust issue, and it might be better to release the code first and then ask for money, but as it looks this guy has a good reputation in the community so i dont see too much of a problem.
Either build your closed source business, or try to earn from an open source product to pay the bills.
1) What is the current state of the source code? It could be a mess.
2) The value of open source is mostly in continued developments, support, community, not just in releasing the code itself.
3) If you have this mindset, who guarantees me that tomorrow you'll write plugins that are closed and ask again for money to release?
Starting up a project with a crowd funding does not make it impossible to later fund continued maintenance by selling support and such. It is a way in which I'm safeguarding my initial investment.
In short, I still fail to see the problem.
EDIT: cut down for brevity
So you know wrote code for 1 month, and you want to be crowdsourced. Ok, what's the plan for the continued development of the project? Code as it is is worth zero without bugfixes, evolution, and a community.
B) I'm debating whether to take the OSS or commercial route, since I do need money to live
C) I have a reputation for maintaining software in a serious way
So I'm asking people "If this is worth 10k to you, let's go the open-source route". So far, it looks as if it is worth that to people. Unless I'll turn around and act like a complete bandit, destroying my reputation, the model works. It does require the reputation part, I guess. But I'm quite puzzled why you are so hostile to it.
I think there are things that play nicely with the open source model, that is, ways to make money that don't interact in a bad way with the culture of free software. I don't think that to ask to be payed to open source stuff is in line with the OSS movement / culture.
Ok, now that the hostile bit is discussed, my argument is that it makes more sense IMHO if you say, there are N people willing to donate me 10$ per year if I open source this stuff? It's still wrong IMHO as a model, but at least makes sense, that is, you will get money to provide the software relevant, updated, documented in the future.
The una tantum system instead is broken, how you'll make money in the future in order to continue the development, since it is clear you don't write this software if you are not backed in some way?
When taking on this project, he presumably factored it in, that he'd want to continue to support it. If not, well, those of us who chipped in probably won't chip in on the next thing he does. I'm willing to take that risk.
And even if he doesn't...so what? It's open source. Other people can continue the work, and if they want to do something ambitious enough to justify crowdfunding as well....more power to them.
You may be right that what he is doing isn't "in line with the OSS movement/culture." Richard Stallman would likely agree with you...he was never one for shades of gray. I would argue that if that is true, that the OSS movement/culture is the thing with the problem.
I wish you luck in meeting the goal (it looks likely you will) and look forward to using what you've produced. I love CodeMirror, btw.
I did start cool open source projects without crowd-funding. It happened at certain points in my life when I didn't really need extra-money (or when I had sufficient free time — essentially the same thing). It is possible.
Today? I'm not sure I could start anything substantial today without funding. My life is not the same as it was 3 years ago. Things change, and somehow paying the bills gradually becomes harder each day than it was the day before—I don't know why life has to suck this way, but so it happens.
There's quite a narrow frame in everyone's life when one can start major free projects without any income — and I'm probably approaching the end of it. Kudos to Marijn for he manages to do so well, and still provide free tools of outstanding quality! (and in case you didn't notice, the demo is quite impressive — the thing is alive, not vaporware).
On the Antirez side now, it's true that a project without a community is as good as dead (he also mentions evolution and bugfixes, but a community is a prerequisite for that). I certainly have projects that could benefit enormously from having a community — but it just didn't happen, for some reason. (OK, I know why: Emacs and Lisp are Just Not Popular).
Tern is not likely to suffer from lacking a community, because it happens that JS is the most popular language on the planet and Tern solves a Hard Problem. You could think of Tern as the smarter big brother of JSLint. JSLint employs brute-force to find potential mistakes, while Tern employs smartness to help you find real semantic errors, or to improve the way you write code. It's unique. I don't think it'll suffer from lacking community—au contraire, I hope the community won't be as invasive as to murder this project by bringing into it tons of "I'd like my code to look that way" features — but then again, I trust Marijn for being able to trim down feature requests and leave in only what's meaningful, rather than particular use cases; and for particular use cases he will totally be able to make a living by providing custom support and development and this will eventually raise the quality of the project on the whole.
You're saying, A value proposition worth paying for would focus on support, not software availability. Yeah?
I'm unsure whether that's always the case. And as the OP is pointing out, support is implicitly included by his need to maintain a reputation. I'm not sure the profit model has to explicitly include it.
That, and View Source.
Does it harm you in some way?
If it works, it works. If it doesn't, it doesn't. And either way, we've learned something. There's one one approach or set of approaches that are blessed and known to work 100% of the time.
I was more than happy to support it given the fine work that he's done in the past and how easy it has been to get answers from him about CodeMirror.
If this helps him produce more software or release some of what he's already written, then great. I'd rather he do this than get a more traditional job and have the fruits of his labor locked up.
But either way... what's the harm in trying a different approach? What's the harm in (potentially) giving him the opportunity to continue doing what he enjoys and does well?
If you don't want to give him that opportunity, that's fine. But there's little need to cast aspersions, right?
I think it's an excellent model. I hope it makes the target, so he doesn't have to go the closed source route with it. And I hope more people do things this way.
Even if he doesn't continue developing it (leaving it to others to do so) or if he wants to write closed source plug ins, so what? That's not what the 10k is for. If he wants to make a big enhancement to it in a year and crowd fund that, I say go for it.