Store not being read or recognized - extjs

I get this error when I try to start up my ExtJS 4.2 app:
Uncaught TypeError: Cannot read property 'buffered' of undefined
I've double checked all my store ids and and names to ensure that they are all spelt correctly but I'm still having this issue :(. Is there anything else I could try to solve this error?
Thanks in advance.

I typically get this error when one of my grids is referencing a store that has not been defined in either the controller instantiating the view or app.js (depending on how the app is structured)

In my case, usign Sencha Architect 3.5, I had to drag to the Store Section the store and it works again. I didn't know when the Application loss the relation with the store but doing that it's working again.

Related

TypeError: Cannot read properties of null (reading 'index') (https://mantine.dev/)

I'm using Rich Text Editor of Mantine in a next js project.
It's working fine for all the control except for List (both ordered & unordered).
When using list in this rte, it gives the following error
TypeError: Cannot read properties of null (reading 'index')
I'm using the code given in official documentation here.
I've gone through the issues on Mantine github but none of that seem to fix this issue.
Can anyone please tell me how to fix this, or suggest any other rich text editor for react / next.
Thanks.
Most likely this issue is caused by react strict mode, try disabling it
Disabling react strict mode does cause the error go away. However, unorderedlist or orderedlist does not work as expected. No bullet points or numbers are shown before the indented line. But, yes, the lines are indented.

Liferay 7.1 npm-react-module localization

I'm trying to include localization into my npm-react-module, but I have failed receiving the value for the corresponding key from the Langugage.properties file. It simply returns the key. I did some research but I couldn't find any source that would help me solve my problem.
In the code which I will show you bellow, I have included a Language.properties file into my module. In my portlet, I have included the needed configuration for the language properties. I have also tried to add a separate file for a specific locale, but that didn't help me either.
This is an example of my portlet configuration:
"javax.portlet.resource-bundle=content.Language"
This is an example content from my Language.properties file:
example-key=example-value
This is how I'm trying to access the value in my React Component:
<h1> {Liferay.Language.get('example-key')} </h1>
But it only returns "example-key" instead of "example-value".
In my view.jsp file I am able to retrieve the corresponding values using
<liferay-ui:message key='example-key'/>
I have tried this method: https://portal.liferay.dev/docs/7-1/tutorials/-/knowledge_base/t/localizing-your-portlet but it didn't work either. Did anyone get this to work properly in their npm-react-module? I really don't want to spend time implementing my own localization service. Thanks!
Liferay.Language.get('key') gets text replaced by the build mechanism. Therefore there is no actual object/class to do this. I have been trying to get this to work myself and have resolved that I will have to do internationalization on my own.
localizing is done only in build time meaning if you have a language
key that generated dynamicly , you can't localizate it or for example
if you get a key from api fetch and need to localizate it, you can't
beacuse Liferay localization method for react (
Liferay.Language.get("yourLanguageKey") ) its undefined in runtime and
you can't use it.
from: https://npm.io/package/liferay-react-runtime-localization

Dot notation showing up as undefined in AngularFire

{
"$id":"-KMVCUSAsz92c0Hp296i",
"$priority":null,
"aQuestion":"what is your favorite color",
"option1":{"option":"red","vote":1},
"option2":{"option":"blue","vote":2},
"option3":{"option":"green","vote":0},
"option4":{"option":"yellow","vote":0}
}
So using dot notation to access this object from Firebase, using vm.data.$id and vm.data.$priority returns the correct value. However using vm.data.aQuestion or vm.data.option1 yields undefined. I've looked at several posts, however none have fixed this issue for me. Is there something simple I'm not understanding?
Okay, I think I may have figured it out. I was luckily able to find this post shortly after reading Surjeet's about something making my field null or empty.
Cannot access Firebase object attributes. Value displayed as undefined ANGULARFIRE
Because Firebase values are loaded asynchronously, the value did not load. after using vm.data.$loaded().then was I able to retrieve through dot notation. Not sure if this is the best way, but it works. Thanks everyone for your help.
Also, if anyone that reads this has a better way to go about this issue, please let me know. Thanks!
Try to see have you did something in your code which is making your object field null.
If not then,
Try this one vm.data['aQuestion']

Backbone.Paginator : cannot read property 'requestPager' why?

I downloaded the Backbone.Paginator production version. I went through the example, copied and pasted everything exactly the way it appears, but I keep getting cannot read property 'requestPager'. What am I doing wrong? I already made the reference to the backbone.paginator.min.js, what else do I need to do?
Thanks
EDIT:
If I remove paginator, my application works fine. It displays data without any issue.
The problem was that I had referenced backbone.paginator after my collections. It's small things like these that I still have to get used to and be aware of.

Mootools and ExtJs 4.x seem to be incompatible, how to solve?

Mootools and ExtJs have a compatibility issue when used on the same page. Mootools throws the following error :
Uncaught TypeError: Property 'id' of object #<HTMLDocument> is not a function
How can we use both frameworks side by side ? Is there a workaround ?
This looks like a document.id('..') reference issue, it is defined but it's not the mootools method...
Nothing will work if it's not pointed to the mootools method.
I would argue that ExtJS or your app has added a property id to document, which is not a function as is likely a String or another primitive.
Pretty sure that ExtJS would not have been overwriting document.id, especially given that they (Sencha) employed MooTools core team dev #subtlegradient (thomas aylott) who co-wrote the Slick selector engine and helped engineer the document.id transition in MooTools from the simple $ in 1.11
You probably cannot do document.id = $ to restore it as it's by reference and it's been overwritten.
Only chance is to try loading MooTools after ExtJS is loaded and started - or load MooTools, save a ref like document.$id = document.id; immediately after, load ExtJS and then restore it back when ready via document.id = document.$id; delete document.$id - still no guarantees this will run at the right time. you really need to see what modifies your document object in web inspector (you can add a watcher)

Resources