Anh Tran, Here's what I'm confused about. Maybe you can help me.
My understanding is that ACF doesn't use the standard WP procedures/structures in order to create/manage custom fields (for example, using the db to define custom fields instead of using code.) Therefore, it's understandable why ACF would require an integrator to work with another plugin such as FacetWP.
What I'm confused about is that I believe that MB does use standard WP procedure & data structures, and not some custom system, like ACF. So, if this is the case, why does FacetWP require use of the MB-FacetWP Integrator to integrate the custom fields created/managed via MB. (I have read class-mb-facetwp-integrator.php several times and unfortunately, my skill level is not sufficient to understand what it is doing & why it is necessary.)
Any help you can give me in clearing up my confusion would be greatly appreciated. I hope I have explained this clearly.
Thanks for asking the great question! You're indeed right about 90%.
Meta Box uses WordPress standard way to store post meta. So it should work in most cases as normal custom fields for FacetWP.
However, there are 2 cases that we need to handle: clone and multiple fields, as you can see in this code: https://i.imgur.com/ONbJioO.png
The reason is clone values is saved as serialized array in the post meta, thus, it's not the standard WP way. Actually, WP doesn't have mechanism to save such kind of data yet. So, we have to find a way to work on that. Because FacetWP doesn't process serialized array, we have to do that.
The other case of field with multiple values, although it's the WP's way, but I still pull all the data just for sure.
So, if all of your fields (or the fields you want to filter) is just normal / uncloneable fields, you can just use FacetWP without any problem. In other cases, the extension will help.
Anh Tran, thank you for the clarification. So, just to make sure, I would only use the Integrator if I am using custom fields that are either clone or multiple fields (or both).
So, if none of my custom fields are clone or multiple, then I don't need to include & activate the Integrator extension?
Yes, that's right.