If we are to build an app that supports multiple e-comm platforms like Shopify, Bigcommerce, Magento, Generic 3rd party API etc. , what should be our approach ? Should we build separate apps ( codebases ) for each of them or a common codebase with extensions ?
P.S : I have built an app on Shopify using Python, Django stack
My recommendation would be to focus on writing just the code unique to your app (completely separate and irrelevant to any specific platform) and then build your own public (or internal) REST/SOAP API around this code base.
This way, from there, you can then focus on building platform-specific applications without ever needing to mess with the core code, while establishing a common/set methodology of building unique platform versions (at least 50% of the code will be reusable amongst the individual platform extensions). Also though, having your own API made publicly available would even allow users on other platforms to use your API to build their own integrations into their own eCommerce platform - this is actually a critical business move of becoming first to market as your app is now actually made available for every platform, even if a platform specific version has not been internally developed yet.