Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
What are the advantages of using requireJS if all the script files are merged into one in production?
Im working on a multiple page project.
You only merge the files for staging and production. In development you keep them separate.
This lets you manage your JavaScript by dividing it into discrete units. This makes it easier to test, easier to reuse and easier to find the piece of code you need to change.
Related
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 2 years ago.
Improve this question
Should I create multiple docker containers to host my frontend and backend source code?
With traditional approach (Nginx and Reverse proxy in Ubuntu) I don't separate them. What's the advantage of separating both?
Yes, it's a good practice to achieve resilience, here where I work, we run 3 instances of the same container, and in the front of then, we have a load balancer, with that, if one instance is down, we have other 2 to receive the traffic.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 3 years ago.
Improve this question
I want to know the best folder structure for typescript-express backend project.
Presently i am fallowing the bellow structure.
src-
-controllers
-models
-middleware
-utils
I am generally following this guide: https://gist.github.com/tracker1/59f2c13044315f88bee9
This can be applied to most javascript projects (nodejs or frontend-only) and is (kind of) used by a lot of CLIs like the vue and react cli.
Your controllers, models etc. should therefore be inside the SRC folder.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 4 years ago.
Improve this question
React with JavaScript or TypeScript?
which is best if typescript is please explain why it is.
This will depend on the size and type of the project. If a small project is developed by, for example, only one developer is sufficient for JS, if one is a large enterprise solution, then it is a better typecript.
The TypeScrip main features:
optional static typing (the key here is optional)
type Inference, which gives some of the benefits of types
access to ES6 and ES7 features
the ability to compile down to a version of JavaScript that runs on all browsers
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 6 years ago.
Improve this question
I am working to build my own custom UI library providing a feature like customized form elements, cards, tabular view and much more, most of the feature is inherited from bootstrap. there is a lot of javascript code and I am looking for proper standard and format to be followed while writing any javascript library to make the code manageable and can be reused.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
I struggle to find any suggestions how to organize RactiveJs code.
Currently I just put RactiveJs code to the bottom of the page. It was okay till my scripts were small. But the bigger they are the more problem it causes. I'm considering moving the RactiveJs code to separate js files, may be using some pattern (Module?).
Are there any guidelines in this regards?
There is a spec for component-per-file: https://github.com/ractivejs/component-spec/ and there are loaders that allow you to incorporate them into the page.
However, Ractive doesn't force you to use this pattern. You are free to experiment whatever convention works for you.