Skip to content

Can not make Postgres connection work #558

Discussion options

You must be logged in to vote

Hi @ahmedrshdy
The onEnter event is only available for context blocks, the Drawer block is a container block. Try adding the Request action to the context block in which the Drawer is placed.

For more detail on how this works, the first block of a page must be a context block type. This creates a state and all the scaffolding required to execute requests, actions, etc. All child blocks of a context share the same state. Since actions fire sequentially, there is only one onEnter event per context and it is defined on the context block.

For most purposes, one context per page is all you need. Also, see Context and State and Events and Actions for more details.

I have not tested it, please l…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@AhmedBytesBits
Comment options

@Gervwyk
Comment options

@AhmedBytesBits
Comment options

Answer selected by Gervwyk
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants