Live data from Hacker News

How we do Vue at GitLab: one year later

about.gitlab.com

101–110 of 208 posts

Re: How we do Vue at GitLab: one year later

#101

Earlier quoted context omitted.

Rookie Vue dev here. I found Vue super easy to understand and to start using for my own simple stuff basically from day 1. Gradually as my tiny projects grew in complexity, I naturally started to feel the need to manage state better. And again, Vue docs led me gradually thru pure-Vue solutions towards VueX. It all felt very naturally, the documentation didn’t push me to anything, just gave me answers at my pace. Can’…

How are you learning Vue? Looking to expand my toolkit.

Awesome Vue has a good list of many vue resources: https://github.com/vuejs/awesome-vue

Re: How we do Vue at GitLab: one year later

#102

Earlier quoted context omitted.

Rookie Vue dev here. I found Vue super easy to understand and to start using for my own simple stuff basically from day 1. Gradually as my tiny projects grew in complexity, I naturally started to feel the need to manage state better. And again, Vue docs led me gradually thru pure-Vue solutions towards VueX. It all felt very naturally, the documentation didn’t push me to anything, just gave me answers at my pace. Can’…

How are you learning Vue? Looking to expand my toolkit.

Vue official docs/tutorial are great. I also highly recommend Laracasts free Vue lessons:

* https://laracasts.com/series/learn-vue-2-step-by-step * https://laracasts.com/series/testing-vue

Re: How we do Vue at GitLab: one year later

#103

Earlier quoted context omitted.

I implore you to checkout create-react-app to get a hello world really quick: https://github.com/facebookincubator/create-react-app npm install -g create-react-app create-react-app my-app cd my-app/ npm start Your sentiment is correct that tooling around these pieces of technology needs to always be first class. React failed miserably, and Vue did an AMAZING job. I'm probably starting to sound like a shill for React.…

I used that. I took me a huge time just to understand what all the tooling was doing, how to integrate it in my current stack and how it was going to affect my current project. My pet peeve with react is that I can't just code. I have to stop every 10 steps and reflect on the tool I use, instead of the problem I'm trying to solve.

I have no idea what you are talking about. React doesn't require any tooling. Drop a reference to React from some cdn in your HTML file and you are good to go. People confuse the myriad of libraries and tools complementary to React for React. You don't need create react app for Hello world.

Create React App gives you a zero configuration way to not only write hello world, but also bootstrap a non-trivial production ready application. In the company I work for, we were previously using JSPM/SystemJS/Gulp. We replaced all of that with create-react-app. It allows you to very easily bootstrap existing applications on top of it: http://fredrik.anderzon.se/2016/12/04/adding-create-react-ap...

And if you want full control of your project, you can "eject" and CRA will generate the webpack configuration file being used so that you can tweak to your heart's content.

I use React daily, and the whole experience has been extremely pleasant.

Re: How we do Vue at GitLab: one year later

#104

I would strongly disagree that it is ok to use jQuery with Vue. I mean sure, it's ok in that most of the time it isn't going to hurt or break anything, at least if you are just using it to query elements from the DOM. However, I would argue that is not ok in that it should never be necessary and it's use would be a code smell to me and indicate that the code in question is likely not using Vue properly. I suspect it…

Vue and jquery works ok together. First, you can gradualy migrate from jquery dom to vue. As both are very light, having both is not bloated. Plus, you need something to do ajax anyway, and if your site uses it, why add axios as well? Actually I'd say that vue is probably the best tech if you want to progressively improve a legacy jquery heavy website instead of doing a complete rewrite.

Isn't fetch widespread enough to use these days?

Re: How we do Vue at GitLab: one year later

#105
post #12

Earlier quoted context omitted.

Funny thing is, Vue wihtout extras is more complex than React without extras.

Nope. Nope. Nope. Trainer here. I train in React and in Vue. My students do 3 times the work with raw vue than in raw react. Every one of them. All the time. It's not even on the same map.

Also a trainer and my students do 6x the amount of work in raw react than with vue. Every one of them, all the time. Looks like Vue sux.

EDIT:

In case this wasn't clear to you, I made this comment to highlight how ridiculous you sound. I don't know about you, but I don't select my tools based on how easy it is for students to learn them. I am a professional software engineer. Tool selection is driven by requirements.

> Add webpack to the mix, make them fight with JSX that doesn't want to do what they need and voila, you get a sad student.

You have made several comments here that lead me to believe that you do not have a good grasp of React and the React ecosystem. I think you are unfairly prejudiced against React because you had a hard time picking it up. This is not the case for everyone. And your students might do 3x more work in Vue because they might have a bad instructor.

Do yourself a favor and forget Redux, and just use Create React App to write a simple application using good old React setState.

Re: How we do Vue at GitLab: one year later

#106
post #93
post #84

Earlier quoted context omitted.

> You're writing scss within the text blocks. So, yeah, you lose all the syntax highlighting etc. that comes with just writing normal CSS. I don't think it's unreasonable for a designer to object to that - how would you feel if you were presented with a build system that required you to write all your JavaScript inside one big string statement? Maybe it's just me, but I don't find it intuitive at all. `styled` has pr…

> So, yeah, you lose all the syntax highlighting etc. that comes with just writing normal CSS Except you don't. Editor support is quite good, and syntax highlighting, syntax validation, auto-completion, etc all work. I mean, same way with Vue really. If the editor didn't know wtf a Vue file is, you'd lose all the integration too.

> I mean, same way with Vue really. If the editor didn't know wtf a Vue file is, you'd lose all the integration too.

In a way, that's fair. In another way, the example single component Vue file I linked to is an HTML file. It has a tag and a tag. Just associate .vue with HTML and you're done.

That gets to my broader point as well - styled-components reinvents the way you declare styles and the way you apply styles, and requires the entire thing to be written as a JS file. And for what? I still don't understand what the advantage is over a syntax everyone already knows (and has validators for already!)

Re: How we do Vue at GitLab: one year later

#107

Earlier quoted context omitted.

Same. That and the fact it took me an afternoon to get an hello world with react and understand it. And 20 minutes with Vue.

I implore you to checkout create-react-app to get a hello world really quick: https://github.com/facebookincubator/create-react-app npm install -g create-react-app create-react-app my-app cd my-app/ npm start Your sentiment is correct that tooling around these pieces of technology needs to always be first class. React failed miserably, and Vue did an AMAZING job. I'm probably starting to sound like a shill for React.…

What do you mean by “React failed miserably”?

Re: How we do Vue at GitLab: one year later

#108
post #81

Earlier quoted context omitted.

React is the new JQuery, I really don't see Vue and Angular being in the same world as React.

So, pretty soon we should see youdonotneedreact.com websites popping up?

React is opinionated document.write

Re: How we do Vue at GitLab: one year later

#109
post #61

Earlier quoted context omitted.

In general it's best to push your comfort boundaries. It's called learning. I'm not saying React is better than Vue (I honestly think they are very similar). Just that picking a technology based on whether it challenges you or not is probably not the best strategy.

I strongly disagree. Parent poster specifically states 'as a long time jquery dev...', so their objectives almost certainly do not aline with those of a student. Indeed, "picking a technology based on whether it challenges you or not..." Has almost no value at all for a prudent, real-world dev making real world software.

I think it has a value if you value long term employability > short term employability.

If you mainly choose technology based on the fact it doesn't take any effort to learn at all, you will soon hit a wall on what software you can use overall.

Re: How we do Vue at GitLab: one year later

#110
post #106
post #93

Earlier quoted context omitted.

> So, yeah, you lose all the syntax highlighting etc. that comes with just writing normal CSS Except you don't. Editor support is quite good, and syntax highlighting, syntax validation, auto-completion, etc all work. I mean, same way with Vue really. If the editor didn't know wtf a Vue file is, you'd lose all the integration too.

> I mean, same way with Vue really. If the editor didn't know wtf a Vue file is, you'd lose all the integration too. In a way, that's fair. In another way, the example single component Vue file I linked to is an HTML file. It has a tag and a tag. Just associate .vue with HTML and you're done. That gets to my broader point as well - styled-components reinvents the way you declare styles and the way you apply styles, a…

If you remove styled-component specific tooling from the equation to simplify the argument and just use Glamorous instead of styled-components (which are very close to the same thing except the later is just JS), then it's exactly because of tooling.

The reality is that tooling for templates (even Angular or Mustache style) is pretty terrible. Tooling for CSS is just as terrible. Static analysis or doing simple things like interpolation of data is pretty darn bad.

But JavaScript tooling isn't half bad. It's not the best there is, but its still reasonably advanced. Thus you have React, which is basically just JavaScript and objects. Sure JSX, but when used in React, it's just sugar to define those objects (hyperscript would work just fine too if you don't want to use a compiler, and early on in React's life just creating the objects from factories was just fine. Certainly better than weird templates with bad tooling).

Once it's all javascript, everything works: my linter works (and is certainly more advanced than css linters), both major type systems work, my refactoring tools work, and I have all the language at my disposal without learning anything new to do stuff like conditionally showing or hiding things. No need for an ng-if, v-if or whatever.

The same logic keeps going with styled-components. Associate the styles with a plain old JavaScript object, using javascript constructs (in this case, template strings), and all the tooling to manipulate them, interpolate them, or type check them just works (eg: TypeScript isn't bad at typing interpolations in template strings). And if that's not good enough, Glamorous is just objects so it's even easier.

Now I mentioned both styled-components and glamorous...normally this logic would heavily favor the later, but for some reason, tooling for styled-components have gone above and beyond to make up for the shortcomings of template strings, so it ends up working better for me.

Maybe someday some very motivated people will make tooling for the non-JS parts of ecosystems that are not "all JS", and this point will be moot, but right now the React ecosystem is the one that lets you most heavily lean on tools.

It's probably why it doesn't look so great from a newcomer perspective though: if you're not at a point where you're trying to squeeze every last bits of power from the tooling ecosystem, then it's just overhead and a waste of time.

Post reply on HN