Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Ape Fist
Feb 23, 2007

Nowadays, you can do anything that you want; anal, oral, fisting, but you need to be wearing gloves, condoms, protection.

Vincent Valentine posted:

Do the udemy course or whatever, but I very strongly recommend you just build poo poo 8 hours a day until you get hired. Angular 1 and 2 are the two frameworks where it was extremely apparent to me that the relatively shallow knowledge that internet tutorials give you was insufficient. You really gotta get stuck into it, get frustrated with things not working the way you want, and figure them out afterwards.

Udemy or Egghead.io are both fine, but really just build stuff.

I'd love to be able to dump that much time into it every day but it's going to be enough of a struggle as it is to fit in those 10 hours of Udemy poo poo. But I get where you're coming from. As I said I was incredibly honest with the employer about where I was with Angular (think Codeacademy's angular JS course in terms of depth, maybe a little more but not much) and I actually think my no-bullshit truthfulness about how low I was starting off on the totem pole may have actually landed me the job.

Adbot
ADBOT LOVES YOU

HaB
Jan 5, 2001

What are the odds?

Ape Fist posted:

I'd love to be able to dump that much time into it every day but it's going to be enough of a struggle as it is to fit in those 10 hours of Udemy poo poo. But I get where you're coming from. As I said I was incredibly honest with the employer about where I was with Angular (think Codeacademy's angular JS course in terms of depth, maybe a little more but not much) and I actually think my no-bullshit truthfulness about how low I was starting off on the totem pole may have actually landed me the job.

That. And the fact they probably got
you cheap. ;)

The Udemy course isn't bad. It will be good enough to get you started at least. Just prepare for a lot of refactoring as you learn the "right" way to do things, or even just "better" ways.


bvj191jgl7bBsqF5m posted:

For a first job, which would you take?

Definitely don't take an Angular 1 job in TYOOL 2018. Take the other one.

huhu
Feb 24, 2006

Ape Fist posted:

I'd love to be able to dump that much time into it every day but it's going to be enough of a struggle as it is to fit in those 10 hours of Udemy poo poo. But I get where you're coming from. As I said I was incredibly honest with the employer about where I was with Angular (think Codeacademy's angular JS course in terms of depth, maybe a little more but not much) and I actually think my no-bullshit truthfulness about how low I was starting off on the totem pole may have actually landed me the job.

I got hired to do React and Django and I had finished about 5% of a React project and 1 django project. I got hired because of culture fit and that they knew I could pick the stuff up eventually. Don't sweat it. And worst case scenario, if they let you go (happened to me) or some other terribleness, know that you got paid to continue to learn and you'll have a much easier time landing the next gig.

Ape Fist
Feb 23, 2007

Nowadays, you can do anything that you want; anal, oral, fisting, but you need to be wearing gloves, condoms, protection.

huhu posted:

I got hired to do React and Django and I had finished about 5% of a React project and 1 django project. I got hired because of culture fit and that they knew I could pick the stuff up eventually. Don't sweat it. And worst case scenario, if they let you go (happened to me) or some other terribleness, know that you got paid to continue to learn and you'll have a much easier time landing the next gig.

Yeah I'm here for the learning opportunity big time.

Skandranon
Sep 6, 2008
fucking stupid, dont listen to me

HaB posted:

Definitely don't take an Angular 1 job in TYOOL 2018. Take the other one.

Depends, if he can manage an upgrade from Angular 1 to Angular 2/4/5, he would get some awesome experience that will set his resume for the next 5 years.

HaB
Jan 5, 2001

What are the odds?

Skandranon posted:

Depends, if he can manage an upgrade from Angular 1 to Angular 2/4/5, he would get some awesome experience that will set his resume for the next 5 years.

Perhaps, but I would want to see it written down somewhere on the actual real-world Road Map for the next 6 months, AND see evidence that the same Road Map is actually being USED.

Otherwise, that's a never ending hell of "we'll upgrade when we can devote some resources to it" which is code for "lol never" then 3 years from now all he knows is Angular 1 and can't find another job anywhere.

Skandranon
Sep 6, 2008
fucking stupid, dont listen to me

HaB posted:

Perhaps, but I would want to see it written down somewhere on the actual real-world Road Map for the next 6 months, AND see evidence that the same Road Map is actually being USED.

Otherwise, that's a never ending hell of "we'll upgrade when we can devote some resources to it" which is code for "lol never" then 3 years from now all he knows is Angular 1 and can't find another job anywhere.

If people keep saying "lol never" to upgrading then there will always be jobs for Angular 1.

prom candy
Dec 16, 2005

Only I may dance
what is the raddest way to do CSS-in-JS as of January 11th, 2018?

Skandranon
Sep 6, 2008
fucking stupid, dont listen to me

prom candy posted:

what is the raddest way to do CSS-in-JS as of January 11th, 2018?

Use AJAX to dynamically fetch CSS fragments from a REST backend.

prom candy
Dec 16, 2005

Only I may dance
GET api/v1/header/h1/fontSize

Capri Sun Tzu
Oct 24, 2017

by Reene

bvj191jgl7bBsqF5m posted:

I'm a self-taught dev who is negotiating 2 job offers. Both are small start-ups, one is very well-funded, uses a library I'm familiar with (React), has very good benefits and stuff like unlimited vacation time (minimum 3 weeks), is in a hip location downtown. The company is 4 people with 1 coder after downsizing from 20ish and changing focus.

The other is Angular 1 (haven't used it before), will more than likely offer less pay and less comprehensive benefits with more work, the offices seem kind of cramped for the size of the company (20ish people and expanding), but it seems like it would be a much a better cultural fit full of people who I'd probably like to hang out with outside of work.

For a first job, which would you take?
I wouldn't worry about Angular 1 vs React as much as the stability of the company, pay, and location. Be wary of romanticizing new technologies, React came out <5 years ago and it's anybody's guess what the hot framework will be 5 years from now. I just inherited responsibility for a website that generates millions a year in revenue and runs on jQuery and PHP.

The first offer seems pretty fun but the second company seems a bit more stable from a surface reading so factor that into your decision.

Thermopyle
Jul 1, 2003

...the stupid are cocksure while the intelligent are full of doubt. —Bertrand Russell

https://stackoverflow.blog/2018/01/11/brutal-lifecycle-javascript-frameworks/

prom candy
Dec 16, 2005

Only I may dance
Alright let me rephrase that: are any of you guys doing CSS-in-JS? If so what are you using?

huhu
Feb 24, 2006

prom candy posted:

Alright let me rephrase that: are any of you guys doing CSS-in-JS? If so what are you using?

If you're asking broadly... React with Styled components.

Create an HTML element directly tied to an a tag as a JavaScript const. No classnames no separate HTML, CSS, and JS files. I love it.
code:
const Button = styled.a`
  /* This renders the buttons above... Edit me! */
  display: inline-block;
  border-radius: 3px;
  padding: 0.5rem 0;
  margin: 0.5rem 1rem;
  width: 11rem;
  background: transparent;
  color: white;
  border: 2px solid white;

  /* The GitHub button is a primary button
   * edit this to target it specifically! */
  ${props => props.primary && css`
    background: white;
    color: palevioletred;
  `}
`

Ape Fist
Feb 23, 2007

Nowadays, you can do anything that you want; anal, oral, fisting, but you need to be wearing gloves, condoms, protection.
Going through the Udemy Angular 2 course and it's pretty loving cool, only in as far as (EventBinding) and [PropertyBinding] but as I get into it all I can think is that JavaScript has lost the run of itself and wandered off to a strange place where it's developing wild notions.

Lumpy
Apr 26, 2002

La! La! La! Laaaa!



College Slice

Ape Fist posted:

Going through the Udemy Angular 2 course and it's pretty loving cool, only in as far as (EventBinding) and [PropertyBinding] but as I get into it all I can think is that JavaScript has lost the run of itself and wandered off to a strange place where it's developing wild notions.

Just remember that you are learning Angular, not javascript.

Ape Fist
Feb 23, 2007

Nowadays, you can do anything that you want; anal, oral, fisting, but you need to be wearing gloves, condoms, protection.

Lumpy posted:

Just remember that you are learning Angular, not javascript.

Would it not be more accurate to say Typescript? Also yeah it does almost feel like Angular 2 is almost its own language.

Ape Fist fucked around with this message at 22:34 on Jan 15, 2018

Lumpy
Apr 26, 2002

La! La! La! Laaaa!



College Slice

Ape Fist posted:

Would it not be more accurate to say Typescript? Also I
Yeah it does almost feel like Angular 2 is almost its own language.

Typescript is it's own thing, so you are learning that as well, but one of the things I prefer about React / Redux vs. Angular is that much of the effort involved in learning Angular is lost if you stop using it. React / Redux has such a small footprint (because it's "not a framework" and leaves you to figure out all the stuff Angular does for you) that you learn javascript really well when you use it. Obviously my opinion, and Angular isn't a "bad" thing to learn, but it's sort of like being a jQuery whiz... remove the library, and what can you still do?

Thom ZombieForm
Oct 29, 2010

I will eat you alive
I will eat you alive
I will eat you alive
As a complete react noob am I correct that using bootstrap components requires the installation of a 3rd party package like react-bootstrap? Seems tricky to maintain rather than just hand rolling what you need?

huhu
Feb 24, 2006

Thom ZombieForm posted:

As a complete react noob am I correct that using bootstrap components requires the installation of a 3rd party package like react-bootstrap? Seems tricky to maintain rather than just hand rolling what you need?

I'm a little confused. Are you saying you'd rather maintain your own code than install a third party library? If you need a very small part of Bootstrap, then it probably makes sense to write your own stuff. If you're going to rely on a lot of it, why wouldn't you install it?

Skandranon
Sep 6, 2008
fucking stupid, dont listen to me

huhu posted:

I'm a little confused. Are you saying you'd rather maintain your own code than install a third party library? If you need a very small part of Bootstrap, then it probably makes sense to write your own stuff. If you're going to rely on a lot of it, why wouldn't you install it?

It really depends on what you are building. If you are building a one off project, maybe using Angular and everything it comes with is appropriate. As the thing you build gets larger and deviates more from the Golden Path that Angular sets out, you will end up maintaining more of your own code, and at that point it becomes debatable how useful a giant framework is if you throw out 90% of it.

huhu
Feb 24, 2006

Skandranon posted:

It really depends on what you are building. If you are building a one off project, maybe using Angular and everything it comes with is appropriate. As the thing you build gets larger and deviates more from the Golden Path that Angular sets out, you will end up maintaining more of your own code, and at that point it becomes debatable how useful a giant framework is if you throw out 90% of it.

Good point. We are currently trying to get rid of a library that nobody will update to React 16 and it's a bit of a pain. But I imagine he's probably building a one off project and I think while learning React it'd be good to lean on libraries before deciding to write your own.

Skandranon
Sep 6, 2008
fucking stupid, dont listen to me

huhu posted:

Good point. We are currently trying to get rid of a library that nobody will update to React 16 and it's a bit of a pain. But I imagine he's probably building a one off project and I think while learning React it'd be good to lean on libraries before deciding to write your own.

You're right, I was more replying to a few posts at a time. If you are a complete noob, yeah just use Bootstrap & Lodash. You can replace them later if/when it actually matters.

Ape Fist
Feb 23, 2007

Nowadays, you can do anything that you want; anal, oral, fisting, but you need to be wearing gloves, condoms, protection.

Lumpy posted:

Typescript is it's own thing, so you are learning that as well, but one of the things I prefer about React / Redux vs. Angular is that much of the effort involved in learning Angular is lost if you stop using it. React / Redux has such a small footprint (because it's "not a framework" and leaves you to figure out all the stuff Angular does for you) that you learn javascript really well when you use it. Obviously my opinion, and Angular isn't a "bad" thing to learn, but it's sort of like being a jQuery whiz... remove the library, and what can you still do?

I've fiddled around with some very basic React stuff and yeah it's a little closer to JS I guess than Angular 2 is at this point. But honestly for someone whose still learning about programming from a not-a-pro-but-i-know-how-a-ternary-operator-and-classes-work-i-guess level ultimately it's all just more knowledge to me.

lunar detritus
May 6, 2009


Ape Fist posted:

I've fiddled around with some very basic React stuff and yeah it's a little closer to JS I guess than Angular 2 is at this point. But honestly for someone whose still learning about programming from a not-a-pro-but-i-know-how-a-ternary-operator-and-classes-work-i-guess level ultimately it's all just more knowledge to me.

If you want to add even more alternatives to your list, Vue is a (very) nice compromise between React's pure JS approach and Angular's angular-ish one. I tend to prefer it over both when I can choose.

Ape Fist
Feb 23, 2007

Nowadays, you can do anything that you want; anal, oral, fisting, but you need to be wearing gloves, condoms, protection.
Yeah I've had a peep at Vue and I know it's gaining popularity because it's not as balls to the wall as Angular 2 and it's a little more Angular-like compared to React. Angular-lite I guess? But my job I'm starting next week requires me to study and become familiar with Angular 2. But I think there's going to be a surge of people adopting Vue to get away from the increasingly (and potentially unnecessarily) complexity of Angular.

Skandranon
Sep 6, 2008
fucking stupid, dont listen to me

Ape Fist posted:

Yeah I've had a peep at Vue and I know it's gaining popularity because it's not as balls to the wall as Angular 2 and it's a little more Angular-like compared to React. Angular-lite I guess? But my job I'm starting next week requires me to study and become familiar with Angular 2. But I think there's going to be a surge of people adopting Vue to get away from the increasingly (and potentially unnecessarily) complexity of Angular.

I am certainly in this boat. I think they got some things right in AngularJS but it had too much crap in it. They fixed those things, then floored it with Angular and I don't know if I want to follow them. Vue seems to be maintaining that middle path which I liked, and will certainly be pushing for it at :yotj:. Wish me luck fellow goons. Got my protein shakes and hard-boiled eggs all ready to go.

Nolgthorn
Jan 30, 2001

The pendulum of the mind alternates between sense and nonsense
I used Vue to build my last project and I'm very happy with the result. Vue /w vuex and vue-router. After a year of working with React and Redux, Vue was such a breeze to use, it was delightful.

Ape Fist
Feb 23, 2007

Nowadays, you can do anything that you want; anal, oral, fisting, but you need to be wearing gloves, condoms, protection.
As much as I fully understand and actually appreciate the whole thing where you insert this new Angular 2 syntax directly into the HTML template and because it's operating inside of a component it works, i.e. things like ngIf, ngFor, [], and () events I still feel like sitting here going 'You've gone too far this time, google, too far :argh:' Maybe it's something to do with the idea that I don't like logic bleeding into the HTML the way it does. It's not exactly advanced logic but I dunno, I'm grumbling about absolutely nothing here and there's probably a billion advantages to doing it this way versus something like stuffing a function into the component and calling it.

Chenghiz
Feb 14, 2007

WHITE WHALE
HOLY GRAIL

Ape Fist posted:

As much as I fully understand and actually appreciate the whole thing where you insert this new Angular 2 syntax directly into the HTML template and because it's operating inside of a component it works, i.e. things like ngIf, ngFor, [], and () events I still feel like sitting here going 'You've gone too far this time, google, too far :argh:' Maybe it's something to do with the idea that I don't like logic bleeding into the HTML the way it does. It's not exactly advanced logic but I dunno, I'm grumbling about absolutely nothing here and there's probably a billion advantages to doing it this way versus something like stuffing a function into the component and calling it.

If there is, i'd love to hear it. Javascript already has if blocks and for loops so I've never really understood why all that new syntax was necessary.

HaB
Jan 5, 2001

What are the odds?

Ape Fist posted:

As much as I fully understand and actually appreciate the whole thing where you insert this new Angular 2 syntax directly into the HTML template and because it's operating inside of a component it works, i.e. things like ngIf, ngFor, [], and () events I still feel like sitting here going 'You've gone too far this time, google, too far :argh:' Maybe it's something to do with the idea that I don't like logic bleeding into the HTML the way it does. It's not exactly advanced logic but I dunno, I'm grumbling about absolutely nothing here and there's probably a billion advantages to doing it this way versus something like stuffing a function into the component and calling it.

I started thinking of it as: template logic should be in the template. That seems to have left me in the correct headspace for it.

Pollyanna
Mar 5, 2005

Milk's on them.


IMO if you’re doing anything more complicated than conditionals and iteration in template logic you’re probably doing something wrong.

lunar detritus
May 6, 2009


Pollyanna posted:

IMO if you’re doing anything more complicated than conditionals and iteration in template logic you’re probably doing something wrong.

I think that's all the logic Angular and Vue let you do in their templates anyway. React is more permissive about it since you use javascript directly but I'd expect someone using it would know better.

Thermopyle
Jul 1, 2003

...the stupid are cocksure while the intelligent are full of doubt. —Bertrand Russell

gmq posted:

I think that's all the logic Angular and Vue let you do in their templates anyway. React is more permissive about it since you use javascript directly but I'd expect someone using it would know better.

React is kind of a totally different paradigm and, arguably, the idea of templates doesn't really map well onto how React works.

Skandranon
Sep 6, 2008
fucking stupid, dont listen to me
I think Angular definitely went off the deep end. AngularJS already had issues with allowing too much logic in the template, and it took awhile to beat it out of people to keep the templates thin. Then Angular shows up with even MORE options for putting logic in the template, AND it's no longer even HTML compliant. Keep in mind Angular is written by the GreenTea team, which is Googles internal CMS. They want a framework that makes doing endless forms easy. They don't care what the larger community wants.

Pollyanna
Mar 5, 2005

Milk's on them.


Blindly following Google in practices seems to be a common pastime in the industry anyway.

Maluco Marinero
Jan 18, 2001

Damn that's a
fine elephant.
The problem in having a point of view about what is and is not too powerful for a template, is that it’s perfectly fine for a static website, yet woefully inadequate for building dynamic components, the core building blocks of a dynamic UI.

Turns out it’s real nice to build static websites with components too though, my shop has altogether stopped using templates in favour of React for pretty much everything except email, and the reason is pretty straightforward:

Building isolated, dependable components with a good API is the goal of a component based view layer like React. Neutering the language used in these components makes them ‘simpler’ at the expense of being able to express clearly the isolated/dependable/good API bit. All it does is drive the complexity deeper into directives (if we’re thinking about angular) or surfaces the complexity to the user of the component.

So, your goal of keeping things simple actually gets compromised because now the components can’t be isolated properly, or have lovely APIs, and the template writing designer STILL needs a programmer to help them, nullifying the original goal of having a stripped down template language.


As it stands, I think components with the full flexibility of a proper programming language is a far better default to work from when building UIs, as compared to the original normal of templates being the default for rendering static site. God knows they don’t write UI toolkits for native OSes in a ‘neutered language’, they write them in a complete language and expose a proper API, or at least that’s the goal.

Tres Burritos
Sep 3, 2009

Wait is TypeScript the neutered language here?

Deffon
Mar 28, 2010

Maluco Marinero posted:


God knows they don’t write UI toolkits for native OSes in a ‘neutered language’, they write them in a complete language and expose a proper API, or at least that’s the goal.

I'm not sure what you're getting at with this? Those API:s are hard to work with, which is why most UI toolkit exposes a template engine, like Android layout, iOS Nib, WPF XAML and Qt Qml. You always have a backdoor if you need to code a close to the metal component, so I don't see what coding components in javascript instead of templates buys you in day-to-day usage.

Adbot
ADBOT LOVES YOU

Ape Fist
Feb 23, 2007

Nowadays, you can do anything that you want; anal, oral, fisting, but you need to be wearing gloves, condoms, protection.
Although to be fair how far away from the Chip is something like Angular 2 though. It's built on top of TS, which is on top of JS, running in a client-side engine like V8 which I think is Java which is on top of (I think) Assembly on top of all the 1s and 0s. So that's like 4 layers of abstraction and I'm probably wrong about that.

Edit: V8 is compiled in C++ and then compiled down to machine so that shows what I know.

Ape Fist fucked around with this message at 23:57 on Jan 16, 2018

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply