Skip to content

Conversation

@43081j
Copy link
Contributor

@43081j 43081j commented Jan 7, 2023

as per #2067

      code: `
        <script setup>
          defineEmits(['update:test'])
          console.log('test1')
          defineProps({ test: Boolean })
        </script>
      `,
      output: `
        <script setup>
          defineEmits(['update:test'])
          defineProps({ test: Boolean })
          console.log('test1')
        </script>
      `,
      options: optionsEmitsFirst,

the output ends up as:

        <script setup>
          defineProps({ test: Boolean })
          defineEmits(['update:test'])
          console.log('test1')
        </script>

which contradicts the options passed (emits then props).

this PR fixes that and adds tests for some gaps we had.

Copy link
Member

@ota-meshi ota-meshi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thank you!

@ota-meshi ota-meshi merged commit abdd93d into vuejs:master Jan 7, 2023
@43081j 43081j deleted the macros-order-fix branch January 7, 2023 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants