Join us for
RADAR: AI Edition

packer (version 0.1.3)

scaffold_golem: Golem

Description

Creates the basic structure for golem app with JavaScript.

Usage

scaffold_golem(
  react = FALSE,
  vue = FALSE,
  framework7 = FALSE,
  use_cdn = TRUE,
  edit = interactive()
)

Arguments

react

Whether to include React, internally runs apply_react() and adapts the srcjs/index.js template for React.

vue

Whether to include Vue, internally runs apply_vue() and adapts the srcjs/index.js template for Vue.

framework7

Whether to include Framework7, internally runs apply_framework7() and adapts the srcjs/index.js template for Framework7.

use_cdn

Whether to use the CDN for react, vue or Framework7 dependencies, this is passed to apply_react(), apply_vue() or apply_framework7() if react, vue or framework7 arguments are set to TRUE and ignored otherwise.

edit

Automatically open pertinent files.

Value

TRUE (invisibly) if successfully run.

Details

Only one of react, vue or framework7 can be set to TRUE. use_cdn is not supported for Framework7.

Examples

Run this code
# NOT RUN {
if(interactive()){
# current directory
wd <- getwd()

# create a mock up golem project
tmp <- tmp_golem()

# move to package
setwd(tmp)

# scaffold golem
scaffold_golem()

# clean up
setwd(wd)
tmp_delete(tmp)
}

# }

Run the code above in your browser using DataLab