Provenance in every document
Every document records, in its custom properties:
Word shows them in File > Properties > Custom. The data hash lets you prove which data produced a document without storing the data in it: hash the stored input again and compare.
Your own properties go in
customProperties.
Reading it back
The audit functions are in a separate entry point:Was it changed?
unchanged: the content is exactly what React DOCX generatedmodified: saved again after generation. Opening and saving in Word counts, even without editsunknown: no content hash; not generated by React DOCX, or the property was removed
What changed?
diffDocx compares the paragraphs of two versions, typically the generated file and the corrected one:
added, removed or changed, with the paragraph texts and their positions. Only text is compared: formatting changes and differences in how programs write the XML do not count. Tracked changes count as accepted.
Who changed it?
WithtrackChanges, Word records each edit with author and date. readRevisions lists them:
insertion, deletion or formatting change, with the part it is in (body, header, footer, footnotes) and the text of its paragraph.
