shinyAce (version 0.3.3)

aceAutocomplete: Enable Code Completion for an Ace Code Input

Description

This function dynamically auto complete R code pieces using built-in function utils:::.win32consoleCompletion. Please see rcompgen for details.

Usage

aceAutocomplete(inputId, session = shiny::getDefaultReactiveDomain())

Arguments

inputId

The id of the input object

session

The session object passed to function given to shinyServer

Value

An observer reference class object that is responsible for offering code completion. See observe for more details. You can use suspend or destroy to pause to stop dynamic code completion.

Details

You can implement your own code completer by listening to input$<editorId>_shinyAce_hint where <editorId> is the aceEditor id. The input contains

  • linebuffer: Code/Text at current editing line

  • cursorPosition: Current cursor position at this line