Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
theuser47814yThere are 15+ year old JS codebases that are still in production today and will be running as long as backwards compatibility is ensured. These old codebases tend to be redone though because of changing industry standards and requirements.
-
Seems vague, what does built to last mean? To my mind, that's true of any language.
"Lasting" is generally based on external factors. Whether it is replaced or not is determined by the needs of the environment the code is used in. If the needs don't change dramatically, code could theoretically be used forever. Code being able to last forever by design would require some degree of prescience.
The premise feels a bit like having attachment to your code. Sensible planning means amortizing your application or libary's total value over the duration of its planned lifespan. That means every line of code can be expected to be replaced at the point you sunset the application. This type of approach renders moot any consideration of code survivability beyond that point and makes the target achievable. -
javascript is always readonly by definition after couple of years. So no, you can'y build it to last
TypeScript, yep build away ! -
@theuser it's the point when javaScript codebase reaches unmaintanable state. Ususally couple of years and "hotfixes / hacks"
You can't even know what variuable is doing what -
theuser47814y@NoToJavaScript Sounds like any other badly designed and undocumented codebase. That includes the undoubtedly many TS codebases that uses any for everything. (I am actually maintaining one now and its fucking abhorrent.)
-
@theuser No, I don't agree there.
In TypeScrip I can just do "roght click, find all references"
Or "Go to definition".
I ALWAYS know where and how a variable is used
By JavaScript nature it is not p[ossible in vaniala JS project -
ddit6034y@NoToJavaScript lol your name is NoToJavaScript.
I agree that JS is harder to maintain but not impossible (I have found some ancient node code that I needed to tweak a few years after it was written)
But I generally prefer TS unless it's a really small project.
Related Rants
I just got told that a codebase written in javascript / typescript can't be built to last.
This is the type of rediculous stuff us Web Devs have to put up with.
rant
web development
javascript
typescript