4

向客户端库js.txtcss.txt文件添加注释的语法是什么?

似乎以注释开头的行作为注释,并且以注释开头的行似乎。但是在构建库时,块会导致异常。由于具有特殊含义,这让我想知道添加评论是否真的是一种合适的方式,或者它是否意味着其他东西。这让我想知道发表评论是否真的有效,或者 AEM 是否只是将其视为不存在文件的相对路径。#///* */#base=[root]#//

任何人都知道客户端库的 js.txt 或 css.txt 文件中注释的适当语法的最终答案吗?

4

2 回答 2

2

#clientlibsjs.txtcss.txt. 例如,Adobe 将其用于其版权免责声明:

###############################################################################
# Copyright 2016 Adobe Systems Incorporated
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
###############################################################################

#base=./js
modals.js

请参阅 GitHub 上的官方We Retail演示内容:www.github.com 上的 We Retail Clientlib 示例

于 2017-04-13T20:28:25.270 回答
0
(hash) Import-Package: *

在导入或导出我们的包时,我们必须取消注释这些行。但在 js.txt 或 css.txt 的情况下保持相同:

(hash)base=js

所以 ( hash) 是评论的方式,但有时它不是评论。

于 2017-04-16T05:12:40.627 回答