-
Notifications
You must be signed in to change notification settings - Fork 394
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
45 changed files
with
3,448 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1,231 changes: 1,231 additions & 0 deletions
1,231
packages/@lwc/engine-server/src/__tests__/fixtures/deeply-nested/expected.html
Large diffs are not rendered by default.
Oops, something went wrong.
3 changes: 3 additions & 0 deletions
3
packages/@lwc/engine-server/src/__tests__/fixtures/deeply-nested/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
export const tagName = 'x-component'; | ||
export { default } from 'x/component'; | ||
export * from 'x/component'; |
25 changes: 25 additions & 0 deletions
25
...lwc/engine-server/src/__tests__/fixtures/deeply-nested/modules/x/component/component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<template> | ||
<div> | ||
<template lwc:if={isPositive}> | ||
<template lwc:if={isDivisibleByThree}> | ||
<template for:each={someChildren} for:item="child"> | ||
<span key={child}> | ||
<x-component label={child} remaining={minusOne}></x-component> | ||
</span> | ||
</template> | ||
</template> | ||
<template lwc:elseif={isDivisibleByTwo}> | ||
<div> | ||
<span>two</span> | ||
<x-component remaining={minusOne}></x-component> | ||
</div> | ||
</template> | ||
<template lwc:else> | ||
<x-component remaining={minusOne}></x-component> | ||
</template> | ||
</template> | ||
<template lwc:else> | ||
terminal node | ||
</template> | ||
</div> | ||
</template> |
26 changes: 26 additions & 0 deletions
26
.../@lwc/engine-server/src/__tests__/fixtures/deeply-nested/modules/x/component/component.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import { api, LightningElement } from 'lwc'; | ||
|
||
export default class Component extends LightningElement { | ||
@api remaining = 9; | ||
@api label = 'default'; | ||
|
||
get someChildren() { | ||
return ['a', 'b', 'c']; | ||
} | ||
|
||
get isPositive() { | ||
return this.remaining > 0; | ||
} | ||
|
||
get isDivisibleByThree() { | ||
return (this.remaining % 3) === 0 | ||
} | ||
|
||
get isDivisibleByTwo() { | ||
return (this.remaining % 3) === 0 | ||
} | ||
|
||
get minusOne() { | ||
return this.remaining - 1; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
/* | ||
* Copyright (c) 2023, salesforce.com, inc. | ||
* All rights reserved. | ||
* SPDX-License-Identifier: MIT | ||
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT | ||
*/ | ||
const BASE_CONFIG = require('../../../scripts/jest/base.config'); | ||
|
||
module.exports = { | ||
...BASE_CONFIG, | ||
displayName: 'lwc-ssr-compiler', | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
{ | ||
"//": [ | ||
"THIS FILE IS AUTOGENERATED. If you modify it, it will be rewritten by check-and-rewrite-package-json.js", | ||
"You can safely modify dependencies, devDependencies, keywords, etc., but other props will be overwritten." | ||
], | ||
"name": "@lwc/ssr-compiler", | ||
"version": "6.5.3", | ||
"description": "Compile component for use during server-side rendering", | ||
"keywords": [ | ||
"lwc" | ||
], | ||
"homepage": "https://lwc.dev", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/salesforce/lwc.git", | ||
"directory": "packages/@lwc/ssr-compiler" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/salesforce/lwc/issues" | ||
}, | ||
"license": "MIT", | ||
"publishConfig": { | ||
"access": "public" | ||
}, | ||
"main": "dist/index.cjs.js", | ||
"module": "dist/index.js", | ||
"types": "dist/index.d.ts", | ||
"files": [ | ||
"dist" | ||
], | ||
"scripts": { | ||
"build": "rollup --config ../../../scripts/rollup/rollup.config.js", | ||
"dev": "rollup --config ../../../scripts/rollup/rollup.config.js --watch --no-watch.clearScreen", | ||
"test-manual": "jest ./src/**/*.spec.ts" | ||
}, | ||
"nx": { | ||
"targets": { | ||
"build": { | ||
"outputs": [ | ||
"{projectRoot}/dist" | ||
] | ||
} | ||
} | ||
}, | ||
"dependencies": { | ||
"@lwc/metadata": "6.5.3-0", | ||
"@lwc/sfdc-compiler-utils": "6.5.3-0", | ||
"@lwc/style-compiler": "6.5.3", | ||
"@lwc/template-compiler": "6.5.3", | ||
"acorn": "~8.10.0", | ||
"astring": "^1.8.6", | ||
"estree-toolkit": "^1.7.3", | ||
"immer": "^10.0.3", | ||
"meriyah": "^4.3.8" | ||
}, | ||
"devDependencies": { | ||
"@types/estree": "^1.0.5" | ||
} | ||
} |
Oops, something went wrong.