Skip to content

u/jmking

In this archive from Dec 2010 to Sep 2026

1
posts
287
comments
0
media
1.2k
score

Top posts

Eloquent: More Trouble than it's Worth?

To start - I'd like to clarify that I don't think all ORMs are evil. I've used a bunch across several different frameworks in different languages over the years, and while you'll eventually find yourself in some sort of situation where dropping down to straight SQL/PDO is far more efficient or pract...

8 points30 comments
Open on Reddit

Top comments

Migrating a vanilla PHP app to full blown Laravel is basically a complete re-write.

Instead, it'd be better to refactor what's there into something more familiar in code organization over time. Like introducing a router package so you can start to lift relevant code up into the middleware layers and handle user input via Request objects. You don't even have to do all the routes all at once - the router's wildcard handler could defer to the original code's logic if a route hasn't been implemented in the router yet.

Chipping away at it over time and iterating over re-building is usually the best approach.

169 points

One thing to consider is that JavaScript on the server and JavaScript in the browser are still different enough that there's context-switching.

The Node standard library is vastly different to what's available in the browser. Also the language specifications often diverge. For example, async and await keywords were first available in major browsers back in 2016, but Node didn't get them until Node 7.6 which shipped in late 2017.

While a lot of JS is portable between BE and FE, it's not quite as simple as "it's all the same language".

Also going "full stack" doesn't require you to abandon PHP/Laravel. If you're already comfortable in PHP, that means you have to put less mental energy into learning PHP/Laravel and you can direct that energy into getting more comfortable with JS/Vue.

19 points

Sublime Text 2 is a text editor. PHPStorm is an IDE.

While at a basic level, both edit code, the areas PHPStorm goes beyond is in things like:

  • code completion based on your framework and codebase.
  • integrates with Xdebug inline with breakpoints and realtime variable inspector
  • integrates with PHPUnit
  • Built in terminal, S/FTP
  • Built in database client
  • Built in source control clients ...and a whole bunch of other stuff.

Sublime Text is awesome and my text editor of choice, but I tend to use PHPStorm when I'm working on a larger, custom application where the productivity gains with PHPStorms integrated tools make a big difference.

19 points

Subreddits

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.