For example, I have a file with all-system states:
@startuml
hide empty description
state "Error" AS S0_UNKNOWN
state "Send" AS S1_SOME_START
state "Process" AS S2_SOME_PROCESS
state "Confirmed" AS S3_SOME_CONFIRM
@enduml
Then include this file to diagram file:
@startuml
!include DocumentStatus.puml
[*] --> S1_SOME_START
S1_SOME_START --> S3_SOME_CONFIRM
S3_SOME_CONFIRM --> [*]
@enduml
How to hide unused states? S0_UNKNOWN and S2_SOME_PROCESS? Without writing something as:
hide S0_UNKNOWN
hide S2_SOME_PROCESS
...