-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Dangling chained property #4094
Copy link
Copy link
Closed
Labels
area:member chainslang:javascriptIssues affecting JSIssues affecting JSlocked-due-to-inactivityPlease open a new issue and fill out the template instead of commenting.Please open a new issue and fill out the template instead of commenting.status:needs discussionIssues needing discussion and a decision to be made before action can be takenIssues needing discussion and a decision to be made before action can be taken
Description
Prettier 1.11.1
Playground link
--print-width 75
--no-semi
--trailing-comma all
--use-tabsInput:
for (const edge of edges) {
const adjacencyCount = edge.data.usersCount
const otherBrandsWithThisAdjacencyCount = Object.values(edge.to.edges)
.length
edge.data.tdIdfScore = tfIdf(
adjacencyCount,
sumAdjacencyCounts,
totalBrands,
otherBrandsWithThisAdjacencyCount,
)
}Output:
for (const edge of edges) {
const adjacencyCount = edge.data.usersCount
const otherBrandsWithThisAdjacencyCount = Object.values(edge.to.edges)
.length
edge.data.tdIdfScore = tfIdf(
adjacencyCount,
sumAdjacencyCounts,
totalBrands,
otherBrandsWithThisAdjacencyCount,
)
}Expected behavior:
Would have preferred:
for (const edge of edges) {
const adjacencyCount = edge.data.usersCount
const otherBrandsWithThisAdjacencyCount =
Object
.values(edge.to.edges)
.length
edge.data.tdIdfScore = tfIdf(
adjacencyCount,
sumAdjacencyCounts,
totalBrands,
otherBrandsWithThisAdjacencyCount,
)
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
area:member chainslang:javascriptIssues affecting JSIssues affecting JSlocked-due-to-inactivityPlease open a new issue and fill out the template instead of commenting.Please open a new issue and fill out the template instead of commenting.status:needs discussionIssues needing discussion and a decision to be made before action can be takenIssues needing discussion and a decision to be made before action can be taken