Attribute inheritance inconsistent across production and development
Version
3.2.31
Reproduction link
Provided below
Steps to reproduce
Open development and production links, compare whether class red-bg
is applied to the button.
Development
Vue SFC Link (Vue toggled in Import Map)
Production
Vue SFC Link (Vue toggled in Import Map)
What is expected?
For the development build to have consistent class inheritance logic as the production build
What is actually happening?
The class is only being inherited in development
the root cause is:
the attribute could not be automatically inherited because component renders as a fragment in prod.
but in DEV, we do a special treatment for DEV_ROOT_FRAGMENT
.
duplicate of https://github.com/vuejs/core/issues/5523
Duplicate of #5189 and fixed by 51f3d38
now, a template ↓ , has attribute fallthrough
<template v-if="true">
<span>test</span>
</template>
a template ↓ , has not attribute fallthrough
<template v-if="true">
<!--flag-->
<span>test</span>
</template>
Is this expected behavior?