I had run into this exact issue and this answer was perfect. The reason I replying is because in google searches you are unlikely to find this unless you include CDN in your search. With that included it is a top result as it should be. I hope others will find this in the future if they are looking for solutions when they are searching for how to use mapGetters or mapState or mapActions or mapMutations and they add the line
import { mapMutations } from 'vuex'
only to get the error in the console
Uncaught SyntaxError: Cannot use import statement outside a module
I think the answer would be fairly obvious to someone familiar with including via CND instead of via NPM, but for a relatively new cut-and-paste jockey, like myself, I was struggling to solve this problem. I didn't even think to include cdn in my google search. Only after asking in a different forum did someone suggest this post and/or including it in the search did I find this easy and clear solution.
Hopefully by posting this, the indexing will eventually include this in some of the searches I did without cdn, for the next explorer.