As you can see when you try it, the 3 methods are invoked in a different order. Also, when you invoking from the button you can’t specify additional fields, including the title field.
I believe the current recommendation is to always use the actions attribute, so that actions will occur in an expected order. For convenience, the actions attribute can refer to a macro that contains the actual code to be invoked.
I think you meant to make a button that makes three tiddlers with each having a field named "field2’ and the values outer, actions, inner. However, my version of TiddlyWiki made 3 tiddlers, with only the last two having a field (actions; inner). Was that to be expected because of the order of the instruction?
What does “invoke from the button” mean? – OK I think that means to run the command when pressed. No, wait. then your second sentence doesn’t make sense. Does it mean the command that’s between the carets that hold the term “button”?
It didn’t create a field, because those values can’t be passed when invoked that way. So that’s another argument for not invoking the message in that manner.
The button-widget is one of the very first widgets, that where created, when TW was developed.
During the dev process the widget got more and more parameters for more and more functions, that where needed by TiddlyWiki itself and also by users. So it got a bit messy. …
As always, it depends on your actual usecase. If you “only” want to create a new tiddler as in your OP, it’s OK to use <$button message="tm-new-tiddler">Click!</$button> … It’s readable, it works and everyone should understand what’s going on.
But as soon as you want to do more complex actions and several of them, the best way is as follows:
If action-widgets are used inside the button body. It’s not always guaranteed, that all variables used by the action-widgets are updated in the right way. Variables inside the button widget are evaluated, when the button widget is rendered.
I think, the format above is “best practice”, since all variables are evaluated when the button is clicked.
Message= vs action-sendmessage
The use of the button message parameters is great to create simple action buttons. However the action send message can be used in the button body or in a macro passed to the actions=<<actions-macro>> this allows more sophisticated and conditional actions, as do actions in the button body.
The advantage of both the button message or actions in the button body is the code is in one place and thus easier to read and self documenting. I believe the intention is/was to deprecate the actions in the body (I hope this does not happen).
Having the message/actions and body as alternatives can be very helpful depending on the button, the reusability of the actions and refresh sensitive buttons. If I felt more confident I would publish an ordered table indicating these three approachs and their qualities.
Please see this for important information https://tiddlywiki.com/#ActionWidgets for Action Execution Modes, which gives the possibility of also getting the actions inside an actions=macro to also refresh/update each button click.