require-vuejs icon indicating copy to clipboard operation
require-vuejs copied to clipboard

"define" statement with no semi cause error

Open waiaan opened this issue 5 years ago • 0 comments

cause error :

<template><div></div></template>
<script>
define(['Vue'],function(Vue){})
</script>
<style></style>

no error:

<template><div></div></template>
<script>
define(['Vue'],function(Vue){});
</script>
<style></style>

because the error code text passed to onload.fromText is:

(function (template) {
  define(['Vue'], function (Vue) {

  })  // here is the reason because of IIFE
    (function (css, id) {
      
    })(' ', 1);
})('' +
  ' <div>' +
  ' </div>' +
  '' + '');

also in css_parser , functionString trans

.a  .b{}

to

.a.b{}

waiaan avatar Sep 10 '20 02:09 waiaan