Comments (5)
It's a very interesting idea, but it probably won't work in case when the config contains objects that can't be safely serialized to be stored in the session. An example: say, the component "c" from your example receives as a parameter the instance of its container, the component "sub". Maybe we could implement the caching in such a way, that the developer will decide which components support caching, and which don't. Does it make sense? Would love to hear your opinion.
from netzke-core.
Yes, there should be some option, for example :cache, that indicates how the endpoints will be stored. Also, for the storing in session we could use some cleaning os the Hash itself, to clean-up proc and non-serializable objects. And of course the ensurement that component is cachable should be on developers side. So how do you think? I have experimented with cashing in session, and it appeared to work.
from netzke-core.
I'm not sure why you refer to endpoints where I was thinking about caching the complete config for (deeply nested) components. I suppose, this work would need to be done in invoke_endpoint
in services.rb. So, it will probably be a component's config option which will command Core to store this component's configuration in session cache. I'll be watching closely your experiments if that was the intention of forking Core. Thanks so far!
from netzke-core.
You are right, the main idea was about caching config. I will try to experiment on it closely as I can.
from netzke-core.
Eventually, I came to the conclusion that with the right component design, instantiating the component tree should not be a problem. What we should simply avoid is to put too much into "def configure" (v0.8.x), leaving as much as possible to "def js_configure", which is not called at instantiating the component (e.g. with the aim of processing an endpoint call).
from netzke-core.
Related Issues (20)
- Dynamic component loading broken HOT 3
- Compatibility with Rails asset pipeline or a CDN HOT 2
- Default has_many does not update association HOT 6
- undefined method `current_user' for Netzke::Core:Module HOT 2
- Assigning icon to actions indirectly HOT 1
- Make FeedbackGhost delay configurable HOT 1
- Overriding scope in component declaration has no effect HOT 1
- Dependent model saving HOT 1
- Ext location configure HOT 1
- can't use Ext.form.panel with directSubmit type to directly communicate with endpoint HOT 1
- endpoint response auto convert params key to camelize HOT 1
- Netzke alternative for rails fields_for to manage has_many relation HOT 1
- Status 4.2 integration? HOT 7
- Not effect on rails 4
- Netzke can not work
- netzke 0.8.4 can not work on rails 4.0.2 HOT 1
- Couldn't load component cmp1 error when dynamically loading tab in workspace HOT 3
- Upgrading to sencha 5? HOT 2
- undefined method `attr_accessible' in index.html.erb HOT 2
- Actions can not be added to menu 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 netzke-core.