Add namespacing/modules
See original GitHub issueIs your feature request related to a problem? If yes, please describe the problem.
When we’d like to implement a more broad set of the resources/integrations we’ll encounter a namespacing issue, kind of modules/namespaces/groups would be a handy solution to it.
For example when we’d like to develop the resources for accessing MySQL
and MongoDB
both ORM modules could potentially have a method like mysql:findOne({})
/ mongodb:findOne({})
. There’s actually no way for avoid resource overlapping other than naming convention (egmysql_findOne()
- which actually is not an elegant solution)
Issue Analytics
- State:
- Created 2 years ago
- Comments:6
Top Results From Across the Web
Documentation - Namespaces and Modules - TypeScript
Namespaces are a TypeScript-specific way to organize code. Namespaces are simply named JavaScript objects in the global namespace. This makes namespaces a very ......
Read more >Packaging namespace packages
Namespace packages allow you to split the sub-packages and modules within a single package across multiple, separate distribution packages (referred to as ...
Read more >Using and importing modules and namespaces
A key point with modules is that they produce separate namespaces. A namespace (also called a scope) is simply the domain of control...
Read more >How To Use Namespaces in TypeScript | DigitalOcean
In TypeScript, you can use namespaces to organize your code. Previously known as internal modules, namespaces in TypeScript are based on an ...
Read more >How do I create a namespace package in Python?
There's a standard module, called pkgutil, with which you can 'append' modules to a given namespace.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
On the other hand, what I think we could do is to have a way to return a MySQL object which has a number of fields, each of them being a function (e.g. field
findOne
being a function for finding a single row in a table etc.) and then runmysql.findOne()
. Please note that here we use dot instead of the colon. In AskScript we used colon for the “method” syntax sugar and method chaining, but dot for accessing properties (see e.g. this sample .ask file: https://github.com/CatchTheTornado/askql/blob/master/src/askscript/__tests__/08-objects-records/objects-14-key_access.ask )Blocked by https://github.com/CatchTheTornado/askql/issues/589