garf / laravel-conf Goto Github PK
View Code? Open in Web Editor NEWStore additional config files in JSON, DB, or any other format. Write, Read.
License: MIT License
Store additional config files in JSON, DB, or any other format. Write, Read.
License: MIT License
Hello,
Please can you help with an information, how can I delete a key from json file.
Thanks
Update it to laravel 6, please!
This verson doesn't use array_add, array_set, etc. helpers, only via supporter Arr (Arr::add, Arr::set, Arr::forget...).
It didn't work for me, at all, after a lot of issues I found this solution, I don't know how it worked but I got the idea from the other laravel Facade config files like "view" .
Solution:
in [/vendor/garf/laravel-conf/src/ConfFacade.php]
change this line :
return \Garf\LaravelConf\Contracts\Factory::class;
to this :
return "conf";
I don't know if this is the best solution.
Can you please replace your constructor with this:
public function __construct($filepath)
{
$this->file = ($filepath) ? $filepath : storage_path('app/conf.json');
if (empty($this->config)) {
if (!file_exists($this->file)) {
file_put_contents($this->file, json_encode([]));
}
$this->config = collect(json_decode(file_get_contents($this->file), true));
}
}
or other change so the config path to be customizable?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.