4.0.0 • Published 4 years ago

@highpoint/babel-plugin-meta-html v4.0.0

Weekly downloads
57
License
MIT
Repository
github
Last release
4 years ago

Meta-HTML Babel Plugin

Replaces PeopleSoft meta-HTML found in JavaScript with values from PeopleSoft.

This is useful when developing JavaScript locally.

For example:

const message = '%Message(175, 5)';

will become

const message = 'Custom Properties';

Installation

npm install @highpoint/babel-plugin-meta-html

Usage

Copy .env-sample to your root directory and name it .env. Then populate it with values for your PeopleSoft environment. See "Environment Variables" below.

Add the plugin to your .babelrc file.

Simple example:

{
  "env": {
    "development": {
      "plugins": [
        "@highpoint/meta-html"
      ]
    }
  }
}

Advanced example:

{
  "env": {
    "development": {
      "plugins": [
          [
            "@highpoint/meta-html", {
              "cacheDirectory": "tmp",
              "cacheTTL": 600
            }
          ]
      ]
    }
  }
}

Options

  • cacheDirectory: Defaults to node_modules/.cache/babel-plugin-meta-html. Set to false to disable caching.
  • cacheTTL: Cache's time-to-live value, in seconds. Values older than this will be refreshed. Defaults to 86,400 seconds (one day).

Environment Variables

VariableExample
PS_HOSTNAMEps.example.com
PS_ENVIRONMENTcsdev
PS_NODESA
PS_USERNAMEusername
PS_PASSWORDpassword1
4.0.0

4 years ago

3.0.0

5 years ago

2.0.0

5 years ago

1.0.0

5 years ago

0.2.2

6 years ago

0.2.1

6 years ago

0.2.0

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago