Magento2 source code (at least for the javascript part) separate folders depending on the use case. I'm assuming you talk about the Magento_Checkout
module
Since Magento2 use KnockoutJs there is a view
folder to contain view model of these components (there surely all have a .html
in the template folder with the same path or so).
The action
folder contain functions to call to perform "action" like making an order or adding an item to cart.
The model
is often use to interact with the local storage or data object.
I don't think there's a convention on how to store your javascript files other than storing them in Vendor_Module/view/frontend/web/js
folder. I think it's better to organize your code like the code source.
Also I'm still learning so my answer may not be totally complete.