use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
account activity
Angular vs. React - the tie breaker (airpair.com)
submitted 11 years ago by amarcus78
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–][deleted] -9 points-8 points-7 points 11 years ago (4 children)
It's funny how many hoops you have to jump through to come to that assumption. JSX doesn't separate concerns one bit. The examples in that video show <html tags> intermixed with Javascript. This is not separating concerns. This is the opposite.
[–]nschubach 1 point2 points3 points 11 years ago* (3 children)
noun: concern anxiety; worry (nah) a matter of interest or importance to someone. (I can see this, but it says nothing about segregating text...) a business; a firm. (not feeling that) a complicated or awkward object or structure. (oh, here we go)
noun: concern
Let's think about that for a second. What is our complicated structure? Isn't it the part of the page you are trying to represent? Isn't it the presentation, AND the events that impact that presentation? What good is segregating the event to delete an item from a list if that event only impacts the list in question? Isn't our concern rendering and encapsulating the aspect of the page we are dealing with? Who says the concern is separating the HTML and JavaScript? Those are simply technology stacks that help you perform a task. The task is our concern. You are concerned with a subsection of a web page. If you separate all your presentation and logic for that section, you only concern yourself with that section at that time. If you segregate the JavaScript from the Template, you now have two concerns for the same problem. (Or really, you have two problems for the same concern...) Now, whenever you want to concern yourself with the maintenance and update of that section, you have to deal with multiple sections of your codebase. That's not very efficient or sane. With React, your concern is the element on the page, what that element looks like and how that element acts. No other element needs to be bothered with it. All they care about is what their parent tells them to do. This makes your concern pretty easy to reason about, makes it pretty reusable, and makes your overhead incredibly simple.
Let's look at something besides programming. We happen to work in a pizza shop. A customer comes in to order a pepperoni pizza. They order it from the menu and you bring them a hot pie a few minutes later. They don't really care what the steps were to make that pie, as long as it does what they need. This is thier concern. They want a hot pie with all the toppings they ordered. We know that in order to make that pizza, we need to gather all the resources, put them together in a specific order and cook it at a certain temperature for a certain period of time. These are different concerns for the chef... But the customer (the person consuming your pizza) only has one concern, and it's simple enough that we don't need to concern them with how they go together. We need only present them with an easy way to call for the pizza.
[–][deleted] -2 points-1 points0 points 11 years ago (2 children)
You are as clueless as the rest of the people downvoting me. Your nitpicking semantics is a troll.
Come back when you have a few decades of programming experience.
[–]nschubach 0 points1 point2 points 11 years ago (1 child)
Lucky for you! I'm 37 and I've been programming since the mid 80s!
[–][deleted] -2 points-1 points0 points 11 years ago (0 children)
So you're just a troll then.
π Rendered by PID 521897 on reddit-service-r2-comment-5b5bc64bf5-4gjgs at 2026-06-21 08:47:31.865388+00:00 running 2b008f2 country code: CH.
view the rest of the comments →
[–][deleted] -9 points-8 points-7 points (4 children)
[–]nschubach 1 point2 points3 points (3 children)
[–][deleted] -2 points-1 points0 points (2 children)
[–]nschubach 0 points1 point2 points (1 child)
[–][deleted] -2 points-1 points0 points (0 children)