@extendscript/ind.util.pages

Some page tools for InDesign

Usage no npm install needed!

<script type="module">
  import extendscriptIndUtilPages from 'https://cdn.skypack.dev/@extendscript/ind.util.pages';
</script>

README

pages

version

Utility

Some page tools for InDesign

Install

npm install @extendscript/ind.util.pages

Include

#include 'node_modules/@extendscript/ind.util.pages/pages.js'

Use

Load the module by creating a reference.

var page = Sky.getUtil("pages")

getInfo( page_or_spread, units )

Returns an info object like the one outlined below. The units parameter is optional and defaults to points:

{
  "units"  : "mm",
  "kind"   : "Page",
  "bounds" : [0,0,100,100],
  "width"  : 100,
  "height" : 100,
  "bleedBounds" : [-5,-5,105,105],
  "slugsBounds" : [-15,-15,115,115]
}

getByLabel( pagesArr, labelStr, keyOption )

Returns an array of pages found that matches labelStr.

Test

We can test the code against a range of targets:

npm run test myTarget

We keep a log of test results

More info

Read the docs