Skip to content

Commit

Permalink
Merge pull request #476 from julianrubisch/log-payloads
Browse files Browse the repository at this point in the history
Log reflex payloads client-side
  • Loading branch information
leastbad authored Mar 23, 2021
2 parents 23f2534 + a1460e6 commit e2bb07c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions javascript/log.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ function request (

function success (event) {
const { detail } = event || {}
const { selector } = detail || {}
const { selector, payload } = detail || {}
const { reflexId, target, morph, serverMessage } = detail.stimulusReflex || {}
const reflex = reflexes[reflexId]
const progress =
Expand All @@ -39,7 +39,7 @@ function success (event) {
console.log(
`\u2193 reflex \u2193 ${target} \u2192 ${selector ||
'\u221E'}${progress} ${duration}`,
{ reflexId, morph, operation, halted }
{ reflexId, morph, operation, halted, payload }
)
}

Expand Down

0 comments on commit e2bb07c

Please sign in to comment.