Comments (16)
A few ideas:
@BundleInfo
: reads a key from Bundle.main.infoDictionary@Keychain
: reads and stores values in the Keychain@NotificationHandler
: subscribes to a specific notification and is automatically deallocated@Random
: feed it an array and the get accessor returns a random element@CopyOnWrite
: wrapper forisKnownUniquelyReferenced
(see this post)@Debug
: optional that is only initialized in debug mode (#if DEBUG
)@Release
: optional that is only initialized in release mode (#if RELEASE
)
The names probably need a bit of tweaking 😄
from burritos.
I'd go for @Dependency
from burritos.
Are you guys still working on this repo?
from burritos.
What about to create a poll to vote for the features to impement first?
from burritos.
@Zyphrax maybe @Secret(debug: "", release: "")
?
from burritos.
On top of my mind:
@SafeArray
: the subscript method returns an optional element, nil if the index is out of bounds
from burritos.
@Zyphrax maybe
@Secret(debug: "", release: "")
?
Yes that could work, it reminds me a bit of Ruby Rails environment secrets.
Is it possible to make it generic? Can you for example do:
@Secret(debug: 10, release: 100)
?
from burritos.
@Zyphrax maybe
@Secret(debug: "", release: "")
?Yes that could work, it reminds me a bit of Ruby Rails environment secrets.
Is it possible to make it generic? Can you for example do:
@Secret(debug: 10, release: 100)
?
Absolutely possible to use generics!
I am not sure those "secret" values should be in the souce code. It is a good pattern to keep them in config files/build settings which depend on the build configuration and read via bundle info.
from burritos.
I would like to do a PR for something like @Compressed(maxSizeInMB: 10)
that makes sure UIImage and Data properties are compressed to below a certain maximum limit. What do you think?
from burritos.
@Cached(name: String
)
I'm not even sure PropertyWrapper are the right tool for that, but the idea is to provide a cache key to any optional property that you set later into your code (maybe on the .onAppear, or maybe once you receive data from an async call). The next time you use the same key, it'll fetch the value from the backing storage of @cached (a shared singleton which hold a map of [Key: Value]) and return it if available. And when you set the wrapped value it save it to the cache. Would be quite handy IMO in some case.
from burritos.
@Cached(name: String
) ...
@Dimillian a Cached property wrapper is on the todo list. I am still not sure about the cache implementation itself; either NSCache, a popular 3rd party or an easy way of plug in the cache itself.
from burritos.
Right I didn't saw thanks!
from burritos.
@obfuscate: encrypt and decrypt the string
from burritos.
In Pilgrim I have:
@Assembled var assembly: ApplicationAssembly
to pull items from a dependency container, where the container is responsible for lifecycle and wiring together actors at the composition root.
You can then use @assembled to inject into top-level components (things like view controllers).
Looking forward to @KeyChain
from burritos.
@Persisted
to save Codable
values as JSON to the hard drive.
from burritos.
Hello @guillermomuntaner
Are you going to archive this repository?
from burritos.
Related Issues (13)
- Could it be possible using a property wrapper with Decodable and optional value? HOT 1
- The deploy target version is too high in the podspec HOT 4
- Getting compile error when using @LazyConstant
- Carthage support
- No such module 'Burritos' when installing via SPM HOT 2
- Xcode 11.4.1 (macOS) - Package resolution failed
- AtomicWrite Collections HOT 1
- @Lazy* property wrappers are not thread safe
- Lazy property wrapper doesn't work with closures
- "Float80 is not available on target platform" when building for macOS on Apple Silicon HOT 1
- @Lazy does not work with self
- Rename Expirable as Cached HOT 1
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 burritos.