I am trying to optimize my bundle and I want to transform code from this:
const tmp = '1'
obj['a'] = tmp
str += tmp
to this:
let str = ''
const obj = {}
str += obj['a'] = '1'
Is there any babel plugin for this kind of transformation? Or would it be handled by minifier like Terser?