Skip to content

48 comments

Fucking Angular.

27 points

Blame the dev, not the framework. There's probably a pretty severe syntax error somewhere in their JS, that's usually what stops Angular from rendering the DOM.

18 points

Yup, better translate email, card and flight number

4 points

Using filters on EVERYTHING is the mark of an angular newbie. This kills page performance.

3 points

Angular-gettext > Angular-translate.

2 points

Why's that? I'm probably going to have to internationalize an angular page in the coming months, so I'm looking for options.

1 points

We actually used angular-translate and then switched over to gettext, because:

  1. Translate deals with string id's as the source "language", which means that if something wasn't translated, the user will see "BUTTON_TEXT", whereas gettext uses English (or any other language) as the source and falls back to it.
  2. It was kind of a pain to maintain, since you need to keep track of the language files manually. For example you add HEADER_2, that needs to be added to the file for each of the languages that you're supporting. Also you need to keep track of the ones you're removing, otherwise your files get bloated. Gettext has Grunt/Gulp tools to extract and later compile the translations for you, which you could then automatically push to a translation service (we use Transifex). There were some for translate, but they were regex-based and you know that good ol' saying about parsing HTML with regex.
  3. Our backend is using Django which also has gettext by default. Not a big deal, but at least our translation files are consistent. Also, if it's your thing, you could have one large translation files with strings shared across the frontend and backend.

The couple of drawbacks for gettext are:

  1. It doesn't have the "translate-values" directive, which means that you have the raw Angular expressions in your source string. This hasn't been a big deal so far.
  2. Angular-translate seems to have a bigger community behind it. This also hasn't been a problem for us.
2 points

Aaah, softwaregore. Come for the funny pictures, stay for the incomprehensible programmer talk in the comments.

-2 points

That kind of thing would really make me reconsider flying with them. I mean, I'm sure the planes are safe, I just wouldn't trust them to get me and my luggage on the right plane.

-4 points

I'm pretty sure the guy handling your luggage didn't create their website.

7 points

But did the guy who created the website also create the booking system that tells that guy which luggage goes on which plane? (Or hell, is it even a separate system?) I'm not worried about the people, I'm worried about ending up in Mumbai because of crappy programming.

0 points

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.