Comments (3)
Alternatively: Lenses and Combinator could become private modules, with their functions being re-exported by the Pathex module. This means the behavior of use Pathex would not need to change and documentation would be consolidated.
from pathex.
Updated the title to something that better represents the desired outcome.
from pathex.
Yeah, I've thought about this and I came up with different approaches for this
-
Leave it all as it is. It is simple, explicit and it reflects how people use the library.
For 90% use cases, you justimport Pathex
. For 9% of use cases you alsoimport Pathex.Lenses
. And only for 1% of use casesimport Pathex.Combinator
. And even in most cases, one could just call functions fromPathex.Lenses
orPathex.Combinator
directly -
Move everything to
Pathex
and suggest usingimport Pathex
.
This would add a lot of complex functions with very generic names. Usingonly
option would be even more verbose -
Move everything to
use Pathex
has the same problem as above -
use Pathex, lenses: true, combinator: true
. Nice, but this saves only a few characters and is less explicit
from pathex.
Related Issues (12)
- Error when using tuple with variable in path creation
- Pathex does not compile with elixir 1.14.0-rc0 HOT 2
- feature request: Delete op that succeeds even if path isn't found HOT 4
- Invalid behaviour of `Pathex.delete!` when using concatenation and/or `all` lense HOT 5
- All lens deletion bug HOT 1
- Dialyzer complains about deletion functions HOT 5
- exists?/2 bug
- Is it possible to define collection type when using from_list? HOT 2
- path(y :: :list, :json)
- Delete a key? HOT 4
- How should I create a path from a list? HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pathex.