Comments (11)
@stickypages We can use something like filemtime
.
filemtime — Gets file modification time
Can I know about your use case?
from sleekdb.
Yeah but I don't know which file it is... More so to display a date that says, "last updated". Does that help?
from sleekdb.
@stickypages I think you can add a custom property in your document like "updatedAt" and update the datetime manually. The cache files are not predictable and you will not get a proper datetime on the purpose of showing "last updated".
from sleekdb.
Yeah but I don't know which file to require est to get the datetime
from sleekdb.
@stickypages are you searching for something like this? #47
from sleekdb.
No, just want to know the date when the cache was last updated. Basically the file timestamp but I can't call on the file because I don't know which file to check, there are tons of files.
from sleekdb.
Ok, can you please tell us your use case? For what do you need the timestamp of cached files? We need to know that, to build/ provide a good method for you.
Thank you
from sleekdb.
Yeah, like I was mentioning. it's nice to know when a cache file was updated.
Example: Am I receiving fresh data, or cached data. I don't have a way to know. Also, it's nice to know when the latest file was updated so I can reference it.
from sleekdb.
@stickypages I think I get what you are trying to achieve with the date of the cached file.
Instead of giving the date and letting the user handle the caching by its own we probably should optimize/ redo the caching system to consider updated content.
I will make a new issue for that.
from sleekdb.
#62 Hope this could help you.
from sleekdb.
I will close this issue, feel free to re-open!
from sleekdb.
Related Issues (20)
- Math & Logic operations HOT 2
- nested column select and distinct return empty array HOT 3
- simple join approach
- SleekDB Extension of builtin "named functions" by users
- Allow to use UUIDs as primary keys HOT 2
- How to Run SleekDB HOT 4
- JSON Wildcard Notation HOT 2
- Incorrect escaping of characters?
- Select with alias at join HOT 5
- Class 'SleekDB\Store' not found HOT 2
- how we do search with join HOT 6
- Searching for value in array. HOT 2
- [Feature Request] Simple key-value lookup HOT 1
- [Feature Request] Searching from multiple stores HOT 1
- [SUGGESTION] please set config:timeout default to false HOT 2
- How to set special chars? HOT 7
- Use SleekDB as a readonly store HOT 2
- updateById method undefined HOT 3
- Group by Date
- replace file
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 sleekdb.