0

I have written following script in my pom.xml file and i am getting error in one js file saying "missing name after . operator"

<plugin>
    <groupId>net.alchim31.maven</groupId>
    <artifactId>yuicompressor-maven-plugin</artifactId>
    <version>1.1</version>
    <executions>
        <execution>
            <id>compress_js_css</id>
            <phase>process-resources</phase>
            <goals>
                <goal>compress</goal>
            </goals>
        </execution>
    </executions>
    <configuration>
        <excludes>
            <exclude>src/main/js/*.js</exclude>
            <exclude>src/main/css/*.css</exclude>
        </excludes>
        <jswarn>false</jswarn>
        <nosuffix>true</nosuffix>
    </configuration>
</plugin>
4

1 回答 1

0

我知道现在回答这个问题为时已晚,但我认为它可能对其他人有所帮助。这可能是因为在您的 javascript 文件中不当使用了某些 Java 脚本保留字。您可能已尝试使用“。”访问对象的某些属性值。属于保留密钥集的运算符。所以当你运行 YUI compress 它会自动抛出这个错误

于 2014-10-09T11:45:21.113 回答