- Introduction
- Top-Level Properties
- The "Project Attributes" Object
- The "Files" Object
- The "Project Settings" Object
A CodeKit 3 configuration file stores information about a CodeKit Project, its settings, and all the files it contains.
- The file must named
config.codekit3
or.config.codekit3
. - The file must be located in the root Project folder. (The folder added to CodeKit as a Project.)
The config file is JSON.
There are only two required fields, both of which are top-level properties: settingsFileVersion
and creatorBuild
. All other fields in the Config File are optional.
Keys are case-sensitive. Values are not.
To prevent extraneous diffs during Git commits, CodeKit alphabetically sorts all keys in the Config File. While this is not a requirement, it is handy for users.
Certain numbers in the Config File MUST be parsed as 64-bit integers.
This is because several numbers are actually bitmask values. The specific numerical values that MUST be treated as 64-bit integers are called out in this documentation.
As of 2019, JavaScript cannot represent 64-bit integers natively. The Number
type stops at 53-bits of precision because JavaScript is a god-awful language. Fortunately, JavaScript is introducing the BigInt
type to solve this problem. It is not officially part of the spec right now.
See https://golb.hplar.ch/2019/01/js-bigint-json.html for a workaround.
If you are writing a Config File from scratch and the values you intend to store for the properites that MUST be 64-bit integers do not exceed 53 bits of precision, you can safely write the value as a standard Number
. For example, fileType
can be set to 2 (2^1)
to represent a Sass
file or 4096 (2^12)
to represent a Markdown
file.
If you are reading a Config File, you must treat numbers as 64-bit integers because you do not control whether or not they have bits beyond (2^53) "enabled". It is NOT safe to use Number
to represent numberical values in this case.
.
.
.
.
The top level of the Config File is an object of type {"key": value}
. It looks like this:
{
"AAInfo": "A string generated by CodeKit explaining the purpose of this file to the user",
"buildSteps": [],
"creatorBuild": "31491",
"files": {},
"hooks": [],
"manualImportLinks": {},
"projectAttributes": {},
"projectSettings": {},
"settingsFileVersion": "3"
}
Anything you provide will be overwritten by CodeKit, but you may want to explain that this is a CodeKit configuration file and the app can be downloaded at https://codekitapp.com/
This stores information about each Build Step that a user has defined. It is an Array
of Objects
of type {"key" : value}
. See Details
This is the build number for the version of CodeKit that created this file. The number is visible in CodeKit's About window. You MUST supply a string that contains a number equal to the version of CodeKit you're targeting. CodeKit will ignore any Config File that is missing this value.
As of August 2019, use "31491"
, which is CodeKit 3.9.2. This documentation was written against that CodeKit version.
Whatever build number you enter here is the minimum version of CodeKit that your users should have. If your users have an older version of CodeKit, the Config File will still be read and any values that apply in the older version of the app will be used. However, any values that don't apply to the older version of CodeKit (for a feature that does not exist in the older version) will be discarded permanently.
You are guaranteed forward-compatibility. Your Config File will work in any future release of CodeKit and will be automatically migrated to future formats, if needed.
This is an Object
that stores settings for each individual file in the Project. See Details.
This is an Array
of Objects
of type {"key": value}
that store information about each Hook that is defined for this Project. See Details.
This stores information about import links between files that the user has created via drag-and-drop in CodeKit's UI. When parsing a Config File, you should treat this value as an opaque Array
and write it, unmodified, to your output. When creating a Config File from scratch, you should omit this property. (Drag-and-drop import links are a legacy feature from a time before ES6 module syntax.)
This is an Object
that stores basic biographical information about a Project. See Details
This is an Object
that stores the Project Settings for this Project. It contains configuration for tooling such as ESLint, Babel, Autoprefixer, etc. It also provides "default" values to fall back on when a file in files
(above) is missing a value for a particular setting. If that value is also missing from projectSettings
, CodeKit falls back to the "Defaults for New Projects" that the user has specified. At that level, every possible setting is guaranteed to have a value. See Details
Pass the String
"3"
for this value. CodeKit will ignore any Config File that is missing this value.
.
.
.
.
This top-level property is an Object
that contains basic biographical information about a Project. It looks like this:
"projectAttributes": {
"creationDate": 586072330.73522604,
"displayValue": "The Project Name As Shown in CodeKit's UI",
"displayValueWasSetByUser": 0,
"iconImageName": "brackets_purple",
"iconImageWasSetByUser": 0
}
The date the project was created. Stored as the number of seconds since 00:00:00 UTC on 1 January 2001
in Double
format. If you omit this property, CodeKit will set it to whatever date the user first added this Project to the app, which is probably what you want.
The name of the Project as it appears in the UI. If this is omitted, the name of the Project Root Folder will be used.
If 0
, CodeKit will keep displayValue
in sync with the Project Root Folder name (as the user renames the folder, the displayValue
will be updated to match). If 1
, renaming the folder has no effect on displayValue
. If you omit this value, it defaults to 0
.
This is either the name of a default Project Icon Image from the list below OR a relative path from the Project Root Folder to the image (JPG or PNG) that should be used as the Project Icon. If you supply a relative path, it MUST begin with a /
.
If the specified image does not exist or you omit this property, CodeKit randomly selects a default icon. NOTE: If you want to maintain an exact icon, be sure to set iconImageWasSetByUser
to 1
.
The available Project Icon Names that are bundled into CodeKit are:
- brackets_brown
- brackets_gray
- brackets_orange
- brackets_green
- brackets_magenta
- brackets_purple
- brackets_teal
- brackets-brick
- brackets-forest
- brackets-koamaru
- brackets-pink
- brackets-red
- brackets-slime
- brackets-ucla
- brackets-unblue
- brackets-glace
- brackets-pale
- brackets-payne
- brackets-silver
- brackets-tar
- brackets-azure
- brackets-cafe
- brackets-peach
- brackets-verd
- brackets-rose
- logo-wordpress
- logo-react
- logo-vue
- logo-angular
- meme-harold
- meme-putin
- meme-morpheus
- meme-thinking
- meme-ariel
- meme-ceiling
- meme-cocaine
- meme-facepalm
- meme-fry
- meme-girlfriend
- meme-grumpy
- meme-karate
- meme-lotr
- meme-soon
- meme-trap
- meme-wonka
- meme-kanye
- meme-hart
- meme-owl
- meme-punDog
- meme-angryPicard
- meme-cryingJordan
- meme-kahn
- meme-ive
- meme-dunnoGirl
- meme-greg
- meme-chloe
- meme-leo
- meme-drunkArcher
- meme-daenerys
- meme-gavin
- meme-krieger
- meme-archer
- meme-obama
- meme-maroney
- meme-crying
- meme-confession
- meme-doge
- meme-jake
- meme-ron
- meme-confusedBaby
- meme-angryBaby
- meme-yesBaby
If 0
, CodeKit will automatically set an apple-touch-icon.png
or favicon
image as the Project Icon whenever it finds one anywhere in the Project. If 1
, iconImageName
will not be changed when the app finds one of these files. If you omit this value, it defaults to 0
.
.
.
.
.
This top-level property contains settings for each individual file in the Project. In CodeKit, every file has its own settings, which provides flexibility—one file can be set to minify while another does not, etc.
When a new file is added to a Project for the first time, it won't have an entry in this object. Its initial settings are populated from whichever languageDefaults
property of projectSettings
is appropriate (based on file type). If projectSettings
is missing an entry for a given languageDefaults
, CodeKit falls back to the settings the user has specified under "Defaults For New Projects" within the app. At that level, every setting is guaranteed to have a value.
When creating a Config File, you may find it faster to specify only the file-by-file settings that differ from the projectSettings
you have specified.
When parsing a Config File, you should never discard information from this object, as the user may have customized settings on a file-by-file basis and those customiziations would be lost (and restored to Project Settings values) if you discarded this object.
The files object is keyed by the relative path from the Project Root Folder to each file. The path MUST begin with a /
. The exact keys in each file's object depend on the type of file. Here is an example for an SCSS
file:
"files": {
"/subfolder/file.scss": {
"aP": 0,
"bl": 0,
"dP": 5,
"dS": 0,
"ft": 4,
"ma": 0,
"oA": 2,
"oAP": "/build/subfolder/file.css",
"oF": 0,
"oS": 0,
"uL": 1
},
"/someOtherFile.js": {
...
}
}
Because in Projects with tens of thousands of files, the extra characters add megabytes to the size of the Config File.
.
.
.
All files have the following keys, regardless of their type:
This stands for "File Type". It is one of the Integer
values from the table below. CodeKit uses this (along with other heuristics) to determine the "absolute truth" about a file's type. (A file's extension alone is not a reliable indicator because, for example, *.js
and *.jsm
and *.es6
can all mean "JavaScript".)
CRITICAL: If you are parsing the Config File in JavaScript, you must use BigInt
to represent this value, as it may contain a value that is larger than 2^53
. If you are writing a Config File from scratch, you must use BigInt
to represent this number for all values larger than 2^53
File Type | Extension | Value | Raw Value |
---|---|---|---|
Less | .less | 2^0 | 1 |
Sass | .sass | 2^1 | 2 |
SCSS | .scss | 2^2 | 4 |
Stylus | .styl | 2^3 | 8 |
CSS | .css | 2^4 | 16 |
CoffeeScript | .coffee | 2^5 | 32 |
Literate CoffeeScript | .litcoffee | 2^18 | 262144 |
JavaScript | .js | 2^6 | 64 |
TypeScript | .ts | 2^7 | 128 |
Haml | .haml | 2^8 | 256 |
Pug | .pug | 2^9 | 512 |
Slim | .slim | 2^10 | 1024 |
Kit | .kit | 2^11 | 2048 |
Markdown | .md, .mmd | 2^12 | 4096 |
Other* | [N/A] | 2^13 | 8192 |
JPEG | .jpg, .jpeg | 2^14 | 16384 |
PNG | .png | 2^15 | 32768 |
SVG | .svg | 2^21 | 2097152 |
GIF | .gif | 2^22 | 4194304 |
JSON | .json | 2^19 | 524288 |
Folder (Directory) | [N/A] | 2^16 | 65536 |
This is used for any type of file that is not otherwise listed above. It represents files for which CodeKit has no specific built-in processing. Examples: .php
, .html
, .xml
, .rb
, etc.
Note that CodeKit uses two different ft
values to represent *.scss
and *.sass
files. This is done so that the app is future-proof in case Sass and SCSS files ever adopt different, exclusive options.
Users can tell CodeKit to skip indexing a particular folder. They do this when the folder contains too many items that aren't relevant and indexing it would take a long time (e.g. node_modules
folders). When the user does this, CodeKit does not store settings for each file in the folder, nor does it display those files in the UI. Instead, it asks the user what should be done with this folder (and its contents) when the Project builds—should the folder be ignored, or should it be copied into the build directory? To store this setting, an entry in the files
object may have the value 65536
for ft
, which means it refers to a folder instead of a file.
Do not use any value that is not explicitly listed in the table above. Doing so will cause CodeKit to ignore the entire settings object for that particular file.
This stands for "Output Action". It specifies what CodeKit will do when a given file changes on disk or is processed during a Build. The value is one of:
Value | Action | Details |
---|---|---|
0 | Compile/Process | CodeKit will process this file on change and during Builds. If the file is of a type for which CodeKit does not have built-in processing AND the user has not specified a Hook to handle this type of file, the file will be copied to its output path as-is. |
1 | Ignore | On file-change and during Builds, this file will not be processed, but any files that import it will be. |
2 | Copy | On file-change and during Builds, CodeKit will copy this file as-is to its Output Path, without any processing/compiling. |
This stands for "Output Abbreviated Path". It is the relative path from the Project Root Folder to the Output File you want to create when the given file is processed. It MUST begin with a /
.
Note: CodeKit does allow setting an Output Path to a location outside of the Project Root Folder, but that is extremely discouraged. If the OutputPathIsOutsideProject
flag is set, CodeKit will interpret the path provided here as relative to the disk root instead of the Project Root Folder.
This stands for "Output Flags". It is a bitmask (a single number where the value of each bit represents a boolean). The default value is 0
. Currently, only the first three bits are used:
Bit Position | Name | Explanation |
---|---|---|
0 | OutputActionWasSetByUser | CodeKit automatically changes a file's Output Action to ignore when that file is imported into others. If the value of this bit is 1 , the app will not automatically change the Output Action. CodeKit sets this bit to 1 anytime the user explicitly chooses an Output Action for the file in the UI. |
1 | OutputPathWasSetByUser | CodeKit adjusts a file's Output Path automatically when the file is renamed, moved, or when the Build folder is enabled/disabled. If this bit is set to 1 , the Output Path is locked; it will not be automatically adjusted. This bit is set to 1 when a user explicitly sets an Output Path for a file or clicks the "lock" button in CodeKit's UI. |
2 | OutputPathIsOutsideProject | If this bit is set to 1 , CodeKit interprets the path supplied for the oAP property as relative to the disk root instead of the Project Root Folder. |
.
.
.
In addition to the shared keys common to all files, Less files have these keys:
Autoprefixer
If this value is 1
, CodeKit will run Autoprefixer on the compiled CSS file. If the value is 0
, CodeKit will not run Autoprefixer.
Bless
If this value is 1
, CodeKit will run Bless on the compiled CSS file. If the value is 0
, CodeKit will not run Bless.
Enable JavaScript
If this value is 1
, CodeKit will set the Less compiler's "Enable JavaScript" option to true. If the value is 0
, that option will be set to false.
IE Compatibility
If this value is 1
, CodeKit will enable the "IE Compatibility" option on the Less compiler. If it is 0
, that option will be set to false.
Insecure Imports
If this value is 1
, CodeKit will enable the "Allow Insecure Imports" option on the Less compiler. If it is 0
, that option will be set to false.
Source Map
If this value is 1
, CodeKit will create a source map when compiling this file. If the value is 0
, it will not create a source map.
Math Style
This value controls which "Math Style" CodeKit enables for the Less compiler, which defines when the compiler performs math operations (see the Less docs for details). It is one of these values:
Value | Math Style |
---|---|
0 | Always Except Division Requires Parens |
1 | Always |
2 | Only Inside Parens |
3 | Strict-Legacy (Deprecated) |
Output Style
This controls which output style the Less compiler uses. It is one of these values:
Value | Output Style |
---|---|
0 | Regular |
1 | Compressed (Minified) |
Rewrite URLs
This value determines which setting CodeKit passes to the Less compiler for the "rewrite URLs" option. It is one of these values:
Value | Output Style |
---|---|
0 | Do not rewrite URLs |
1 | Rewrite ALL URLs |
2 | Rewrite only local URLs |
Strict Imports
If this value is 1
, CodeKit will enable the "strict imports" Less compiler option when compiling this file. If the value is 0
, this compiler option is set to false.
Strict Units
If this value is 1
, CodeKit will enable the "strict units" Less compiler option when compiling this file. If the value is 0
, this compiler option is set to false.
.
.
.
In addition to the shared keys common to all files, Sass and SCSS files have these keys:
Autoprefixer
If this value is 1
, CodeKit will run Autoprefixer on the compiled CSS file. If the value is 0
, CodeKit will not run Autoprefixer.
Bless
If this value is 1
, CodeKit will run Bless on the compiled CSS file. If the value is 0
, CodeKit will not run Bless.
Decimal Precision
This is the value passed to the Sass compiler for the "Decimal Precision" option. It should be between 0
and 10
.
Debug Style
This value controls which "Debug Style" CodeKit enables for the Sass compiler. It is one of these values:
Value | Debug Style |
---|---|
0 | None |
1 | Print line numbers above selectors |
2 | Print full debug info |
Source Map
If this value is 1
, CodeKit will create a source map when compiling this file. If the value is 0
, it will not create a source map.
Output Style
This controls which output style the Sass compiler uses. It is one of these values:
Value | Output Style |
---|---|
0 | Nested |
1 | Expanded |
2 | Compact |
3 | Compressed |
Use Libsass
If this value is 1
, CodeKit will use the Libsass compiler. If it is 0
, CodeKit will use the legacy Sass compiler. (Libsass is the default and is highly recommended.)
.
.
.
In addition to the shared keys common to all files, Stylus files have these keys:
Autoprefixer
If this value is 1
, CodeKit will run Autoprefixer on the compiled CSS file. If the value is 0
, CodeKit will not run Autoprefixer.
Bless
If this value is 1
, CodeKit will run Bless on the compiled CSS file. If the value is 0
, CodeKit will not run Bless.
Debug Style
This value controls which "Debug Style" CodeKit enables for the Stylus compiler. It is one of these values:
Value | Debug Style |
---|---|
0 | None |
1 | Print line numbers above selectors |
2 | Print Firebug info |
3 | Print line numbers AND Firebug info |
Import CSS
If this value is 1
, CodeKit will set the Stylus compiler to import CSS files. If it is 0
, that option will be set to false.
Source Map
If this value is 1
, CodeKit will create a source map when compiling this file. If the value is 0
, it will not create a source map.
Output Style
This controls which output style the Stylus compiler uses. It is one of these values:
Value | Output Style |
---|---|
0 | Regular |
1 | Compressed |
Resolve Relative URLs
If this value is 1
, CodeKit will set the Stylus compiler to resolve relative URLs. If the value is 0
, that option will be set to false.
.
.
.
Note: CodeKit allows users to process CSS files with Libsass to minify them, etc. (A CSS file may create another CSS file.) CSS files may also be the output of a Sass, Less, or Stylus file. In all cases, CodeKit stores the same properties for every CSS file—it simply does not use them when the CSS file is an output file.
In addition to the shared keys common to all files, CSS files have these keys:
Autoprefixer
If this value is 1
, CodeKit will run Autoprefixer on the CSS file. If the value is 0
, CodeKit will not run Autoprefixer.
Bless
If this value is 1
, CodeKit will run Bless on the CSS file. If the value is 0
, CodeKit will not run Bless.
Source Map
If this value is 1
, CodeKit will create a source map when compiling this file. If the value is 0
, it will not create a source map.
Output Style
This controls which output style the Libsass compiler uses when processing this CSS file. It is one of these values:
Value | Output Style |
---|---|
0 | Nested |
1 | Expanded |
2 | Compact |
3 | Compressed |
.
.
.
In addition to the shared keys common to all files, CoffeeScript files have these keys. NOTE: These keys apply to both *.coffee
and *.litcoffee
file types.
Source Map
If this value is 1
, CodeKit will create a source map when compiling this file. If the value is 0
, it will not create a source map.
Minify Output
If this value is 1
, CodeKit will run TerserJS on the compiled output, after transpiling is complete (if performed). If the value is 0
, TerserJS will not be run.
Output Style
This controls which output style the CoffeeScript compiler uses when processing this file. It is one of these values:
Value | Output Style |
---|---|
0 | Regular |
1 | No top-level function wrapper |
Syntax Checker Type
This tells CodeKit which syntax checker to run when processing this file. It is one of these values:
Value | Syntax Checker |
---|---|
0 | None |
1 | CoffeeLint |
Transpiler Style
This tells CodeKit which transpiler to run on the output file, once the CoffeeScript file is processed. It is one of these values:
Value | Transpiler |
---|---|
0 | None |
1 | Babel |
.
.
.
Note: CodeKit does not process JavaScript files in-place. That is, a JS file is processed and creates another JS file at a separate path. Some JS files will therefore be "output files" produced by other JS files. CodeKit stores these properties for every JS file—they simply are not used for output files.
In addition to the shared keys common to all files, JavaScript files have these keys:
Source Map
If this value is 1
, CodeKit will create a source map when processing this file. If the value is 0
, it will not create a source map.
Minify Output
If this value is 1
, CodeKit will minify the output file using TerserJS, after transpiling and bundling are complete (if either is performed). If the value is 0
, the output file will not be minified.
Syntax Checker Type
This tells CodeKit which syntax checker to run when processing this file. It is one of the values below. You should strongly prefer ESLint over JSHint or JSLint.
Value | Syntax Checker |
---|---|
0 | None |
1 | JSHint |
2 | JSLint |
3 | ESLint |
Transpiler Style
This tells CodeKit which transpiler to run on this file. It is one of these values:
Value | Transpiler |
---|---|
0 | None |
1 | Babel |
Bundle Format
This value determines whether CodeKit runs RollupJS to bundle ES6 imports in this file and, if so, specifies the format of that bundle. It is one of these values:
Value | Bundle Format |
---|---|
0 | None (Do not bundle) |
1 | AMD |
2 | CommonJS |
3 | ESModule |
4 | IIFE |
5 | SystemJS |
6 | UMD |
.
.
.
NOTE: TypeScript has many configuration options. A subset of those options is available on a file-by-file basis. The complete set of options is available in Project Settings. Options that appear only in Project Settings will apply to ALL TypeScript files in a Project.
In addition to the shared keys common to all files, TypeScript files have these keys:
Create Declaration File
If this value is 1
, CodeKit will set the TypeScript compiler to create a .d.ts
file. If it is 0
, that option will be set to false.
JSX Handling
This value determines how the TypeScript compiler handles JSX code. It is one of these values:
Value | JSX Handling Mode |
---|---|
0 | React |
1 | Preserve |
2 | ReactNative |
Source Map
If this value is 1
, CodeKit will create a source map when processing this file. If the value is 0
, it will not create a source map.
Minify Output
If this value is 1
, CodeKit will minify the output file using TerserJS. If the value is 0
, the output file will not be minified.
Module Resolution Type
This determines how the TypeScript compiler resolves modules. It is one of these values:
Value | Module Resolution |
---|---|
0 | Node |
1 | Classic |
Module Type
Thsi determines the Module Type the TypeScript compiler creates. It is one of these values:
Value | Module Type |
---|---|
0 | CommonJS |
1 | AMD |
2 | System |
3 | UMD |
4 | ES2015 |
5 | ESNext |
Remove Comments
If this value is 1
, CodeKit will enable the "Remove Comments" option on the TypeScript compiler. If it is 0
, that option will be set to false.
Target ECMA Version
This determines the target ECMAScript version for which the TypeScript compiler generates code. It is one of these values:
Value | ECMAScript Version |
---|---|
0 | ES3 |
1 | ES5 |
2 | ES2015 |
3 | ES2016 |
4 | ES2017 |
2018 | ES2018 |
5 | ESNext |
.
.
.
In addition to the shared keys common to all files, HAML files have these keys:
Run Cache Buster
If this value is 1
, CodeKit will scan the compiled Output File for URLs and append a query parameter to each URL that loads a resource. This forces browsers to load the resource from disk rather than serve an outdated, cached copy. If the value is 0
, this step is not performed.
Use CDATA
If this value is 1
, CodeKit will enable the "Use CDATA" option on the HAML compiler. If the value is 0
, that option will be set to false.
Escape HTML Text
If this value is 1
, CodeKit will set the HAML compiler to escape HTML characters. If the value is 0
, it will set that compiler option to false.
Run HTML Minifier
If this value is 1
, CodeKit will run the compiled Output File through an HTML Minifier. If the value is 0
, that will not be done.
No Escape In Attributes
If this value is 1
, CodeKit will set the HAML compiler to avoid escaping HTML characters in attributes. If the value is 0
, that option will be turned off.
Output Format
This specifies which Output Format the HAML compiler should use. It is one of these values:
Value | Output Format |
---|---|
0 | XHTML |
1 | HTML4 |
2 | HTML5 |
Use Double Quotes
If this value is 1
, the HAML compiler will use double-quotes. If the value is 0
, the compiler will use single-quotes.
Use Unix Newlines
If this value is 1
, CodeKit will set the HAML compiler to use Unix newlines. If the value is 0
, that option will be set to false.
.
.
.
NOTE: CodeKit treats *.jade
files as *.pug
files, but compiles the former files with the legacy Jade compiler. The settings are the same for both types of files.
In addition to the shared keys common to all files, Pug files have these keys:
Run Cache Buster
If this value is 1
, CodeKit will scan the compiled Output File for URLs and append a query parameter to each URL that loads a resource. This forces browsers to load the resource from disk rather than serve an outdated, cached copy. If the value is 0
, this step is not performed.
Compile-Debug
If this value is 1
, CodeKit will enable the "Compile Debug" option for the Pug compiler. If the value is 0
, that option will be set to false.
Run HTML Minifier
If this value is 1
, CodeKit will run the compiled Output File through an HTML Minifier. If the value is 0
, that will not be done.
Output Style
This value determines what type of output the Pug compiler produces. It is one of these values:
Value | Output Style |
---|---|
0 | Indented |
1 | Minified |
.
.
.
In addition to the shared keys common to all files, Slim files have these keys:
Run Cache Buster
If this value is 1
, CodeKit will scan the compiled Output File for URLs and append a query parameter to each URL that loads a resource. This forces browsers to load the resource from disk rather than serve an outdated, cached copy. If the value is 0
, this step is not performed.
Compile Only
If this value is 1
, CodeKit will enable the "Compile Only" option on the SLIM compiler. If the value is 0
, that option will be set to false.
Run HTML Minifier
If this value is 1
, CodeKit will run the compiled Output File through an HTML Minifier. If the value is 0
, that will not be done.
Logicless
If this value is 1
, CodeKit will enable the "Logicless Mode" option on the SLIM compiler. If the value is 0
, that option will be set to false.
Output Style
This specifies the style of output the SLIM compiler should write. It is one of these values:
Value | Output Style |
---|---|
0 | Indented |
1 | Minified |
Output Format
This specifies the type of file the SLIM compiler should produce. It is one of these values:
Value | Output Format |
---|---|
0 | HTML |
1 | XHTML |
2 | XML |
Rails Compatible
If this value is 1
, CodeKit will enable the "Generate Rails Compatible Code" option on the SLIM compiler. If the value is 0
, that option will be set to false.
.
.
.
In addition to the shared keys common to all files, Kit files have these keys:
Run Cache Buster
If this value is 1
, CodeKit will scan the compiled Output File for URLs and append a query parameter to each URL that loads a resource. This forces browsers to load the resource from disk rather than serve an outdated, cached copy. If the value is 0
, this step is not performed.
Run HTML Minifier
If this value is 1
, CodeKit will run the compiled Output File through an HTML Minifier. If the value is 0
, that will not be done. Kit files can compile to any type (not just HTML), so enabling this option is only appropriate if the Output File is HTML.
.
.
.
NOTE: CodeKit uses the MultiMarkdown compiler, which adds unique features to Markdown. The available options reflect this.
In addition to the shared keys common to all files, Markdown files have these keys:
Run Cache Buster
If this value is 1
, CodeKit will scan the compiled Output File for URLs and append a query parameter to each URL that loads a resource. This forces browsers to load the resource from disk rather than serve an outdated, cached copy. If the value is 0
, this step is not performed.
Critic Markup Style
This determines how the MMD compiler handles Critic Markup. It is one of these values:
Value | Critic Markup Handling |
---|---|
0 | Ignore |
1 | Accept |
2 | Reject |
Enable Footnotes
If this value is 1
, CodeKit will set the MMD compiler to enable footnotes. If the value is 0
, that option will be set to false.
Enable Labels
If this value is 1
, CodeKit will set the MMD compiler to enable labels. If the value is 0
, that option will be set to false.
Enable Smart Quotes
If this value is 1
, CodeKit will set the MMD compiler to support Smart Quotes. If the value is 0
, that option will be set to false.
Mask Email Addresses
If this value is 1
, CodeKit will set the MMD compiler to mask email addresses. If the value is 0
, that option will be set to false.
Run HTML Minifier
If this value is 1
, CodeKit will run the compiled Output File through an HTML Minifier. If the value is 0
, that will not be done. MultiMarkdown files can compile to several types (not just HTML), so enabling this option is only appropriate if the Output File is HTML.
Output Format
This controls the type of output file that MMD produces when compiling. It is one of these values:
Value | Output Format |
---|---|
0 | HTML |
2 | LaTEX |
3 | Memoir |
4 | Beamer |
6 | FODT |
9 | Original Markdown |
11 | ODT |
12 | TEXT Bundle |
13 | Compressed TEXT Bundle |
14 | ePUB |
Output Style
This controls the style of document that the MMD compiler produces. This option is meaningful only when the Output Format is set to HTML. It is one of these values:
Value | Output Style |
---|---|
0 | Complete HTML Document |
1 | HTML Snippet |
Process HTML
If this value is 1
, the MMD compiler will be set to process HTML. If the value is 0
, the compiler will skip any HTML in the Markdown document.
Parse Metadata
If this value is 1
, the MMD compiler will parse metadata while compiling. If the value is 0
, it will not. (Metadata is a unique MultiMarkdown feature.)
Random Footnote Numbers
If this value is 1
, the MMD compiler will use random numbers for footnotes. If the value is 0
, it will not.
Use Compatibility Mode
If this value is 1
, the MMD compiler will disable support for all MultiMarkdown extensions and process the input file as close as possible to John Gruber's original Markdown spec. If the value is 0
, MultiMarkdown features will be enabled. This setting overrides all others if it's 1
.
.
.
.
In addition to the shared keys common to all files, JSON files have these keys:
Order Output
If this value is 1
, CodeKit will sort keys alphabetically when processing the JSON file. (The order of items in Arrays will not be affected.) If the value is 0
, the order of keys in the file will be random.
Output Style
This controls the style of the processed JSON file. It is one of these values:
Value | Output Style |
---|---|
0 | Pretty-Printed |
1 | Minified |
.
.
.
In addition to the shared keys common to all files, JPEG files have these keys:
Initial Size
This is the size, in bytes, that the JPEG file was the first time CodeKit saw it. (CodeKit allows users to optimize images in-place, so the current size of the file is not necessarily its initial size.)
JPEG Output Format
This determines what type of rendering the optimized JPEG will have. It is one of these values:
Value | Format |
---|---|
0 | Keep Existing Format |
1 | Baseline |
2 | Progressive |
Optimized In Place Lossy
If this value is 1
, this JPEG file has already been optimized in-place with lossy optimization (some quality reduction took place). If the value is 0
, the file has not previously been optimized in-place with lossy compression. CodeKit uses this value to warn the user before optimizing an image in-place multiple times with lossy compression.
Optimized
If this value is 1
, this JPEG file has already been optimized in-place, but that optimization was lossless (no reduction in quality occurred). If the value is 0
, the file has not previously been losslessly optimized in-place.
Quality
This is a value between 0
and 100
, which specifies how aggressive to be when performing lossy optimizations. Higher values retain image quality, lower values sacrifice quality for smaller files. In general, values around 85
produce satisfactory images with 50-70% size reductions.
.
.
.
In addition to the shared keys common to all files, PNG files have these keys:
Initial Size
This is the size, in bytes, that the PNG file was the first time CodeKit saw it. (CodeKit allows users to optimize images in-place, so the current size of the file is not necessarily its initial size.)
Optimized In Place Lossy
If this value is 1
, this PNG file has already been optimized in-place with lossy optimization (some quality reduction took place). If the value is 0
, the file has not previously been optimized in-place with lossy compression. CodeKit uses this value to warn the user before optimizing an image in-place multiple times with lossy compression.
Optimized
If this value is 1
, this PNG file has already been previously optimized in-place, but that optimization was lossless (no reduction in quality occurred). If the value is 0
, the file has not previously been losslessly optimized in-place.
Optimizer Type
This specifies which PNG Optimizer should be used to process this file. NOTE: This value is a bitmask (each bit represents a Boolean on/off). To enable a specific optimizer, you set the bit in that position to 1
. To disable that optimizer, you set the bit to 0
. There are currently only two optimizers. To run only PNGQuant, set the value of oT
to 0
. To run only OptiPNG, set it to 1
.
Bit Position | Optimizer |
---|---|
0 | PNGQuant |
1 | OptiPNG |
Quality
This is a value between 0
and 100
, which specifies how aggressive to be when performing lossy optimizations. Higher values retain image quality, lower values sacrifice quality for smaller files. In general, anything above 80
produces satisfactory images with 50-70% size reductions.
.
.
.
In addition to the shared keys common to all files, SVG files have these keys:
Use MultiPass
If this value is 1
, SVGO will run multiple passes to optimize the file. If the value is 0
, it will run only one pass.
Optimized
If this value is 1
, this SVG file has already been previously optimized in-place. If the value is 0
, the file has not previously been optimized in-place.
Plugin Mask
This is a 64-Bit bitmask: each bit of the number functions as a Boolean to turn a specific SVGO plugin on or off. To turn a plugin ON, set the value of the corresponding bit to 1
. To turn a plugin OFF, set the value of the bit to 0
. The plugin associated with each bit appears in the table below.
WARNING: If you are parsing the Config File in JavaScript, you must use a BigInt
for this value. If you are creating a Config File from scatch, you can use the Number
type as long as you do not need to set any bits over 2^53
.
Bit Position | SVGO Plugin |
---|---|
0 | Cleanup Attributes |
1 | Remove DOCTYPE Declaration |
2 | Remove XML Processing Instructions |
3 | Remove Comments |
4 | Remove Metadata |
5 | Remove Title |
6 | Remove Description |
7 | Remove Useless Definitions |
8 | Remove Editor Namespace Data |
9 | Remove Empty Attributes |
10 | Remove Hidden Elements |
11 | Remove Empty Text Elements |
12 | Remove Empty Containers |
13 | Remove ViewBox |
14 | Cleanup Enable Background |
15 | Minify Styles |
16 | Convert Styles to Attributes |
17 | Convert Colors |
18 | Convert Path Data |
19 | Convert Transform |
20 | Remove Unknowns and Defaults |
21 | Remove Non-Inheritable Group Attributes |
22 | Remove Useless Stroke and Fill |
23 | Remove Unused Namespace |
24 | Cleanup IDs |
25 | Cleanup Numeric Values |
26 | Move Element Attributes to Group |
27 | Move Group Attributes to Elements |
28 | Collapse Groups |
29 | Remove Raster Images |
30 | Merge Paths |
31 | Convert Shape To Path |
32 | Sort Attributes |
34 | Remove Dimensions |
35 | Remove Attributes |
36 | Add Classes to SVG Element |
37 | Remove Style Element |
38 | Remove XML Namespace |
39 | Remove Script Element |
40 | Inline Styles |
41 | Cleanup List of Values |
42 | Remove Off-Canvas Paths |
43 | Reuse Paths |
44 | Sort Defs Children |
45 | Convert Ellipse To Circle |
Pretty Printed
If this value is 1
, SVGO will produce output that is human-readable. If the value is 0
, the output will be minified.
.
.
.
In addition to the shared keys common to all files, GIF files have these keys:
Initial Size
This is the size, in bytes, that the GIF file was the first time CodeKit saw it. (CodeKit allows users to optimize images in-place, so the current size of the file is not necessarily its initial size.)
Optimized
If this value is 1
, this GIF file has already been previously optimized in-place, but that optimization was lossless (no reduction in quality occurred). If the value is 0
, the file has not previously been losslessly optimized in-place.
.
.
.
The Folder type has no additional keys other than the shared keys common to all files.
.
.
.
In addition to the shared keys common to all files, files of "Other" type have these keys:
Run Cache Buster
If this value is 1
, CodeKit will scan this file for URLs and append a query parameter to each URL that loads a resource. This forces browsers to load the resource from disk rather than serve an outdated, cached copy. If the value is 0
, this step is not performed.
Run HTML Minifier
If this value is 1
, CodeKit will run this file through an HTML Minifier. If the value is 0
, that will not be done. Enabling this option is appropriate only if the file is HTML.
.
.
.
.
This is a {"key": value, ...}
Object that stores a massive amount configuration options. There are several main "sections" to Project Settings:
-
Top-Level Settings - These are top-level key/value pairs on the Project Settings object.
-
Language Defaults - When a new file is added to the Project, these objects store the initial settings that should be used for that file. These initial settings are also used as a fallback in case a
file
object does not contain a value for a particular setting. There is one of these objects for each type of file that CodeKit supports. There is ALSO one of these objects for each custom langauge the User has added to CodeKit.
.
.
.
If this value is 1
, CodeKit will stop a Build whenever one file has an error. (Warnings do not count as errors.) If the value is 0
, the Build will continue.
If this value is 1
, CodeKit will reload just stylesheets when a change occurs that affects only CSS. (It will reload the entire page if a change affects other types of files.) If this value is 0
, CodeKit will reload the entire page everytime a browser refresh is triggered.
If this value is 1
, CodeKit's preview server will proxy all requests to the server at the address specified by externalServerAddress
. If this value is 0
, CodeKit will use its internal HTTP server to handle requests.
If this value is 1
, CodeKit will animate changes to CSS when reloading stylesheets. If the value is 0
, it will not.
If this value is 1
, CodeKit will automatically process/compile new files as they are added to the Project. (This is done only if the Project uses a Build folder, since auto-processing files without a Build folder could be destructive.) If the value is 0
, new items are not automatically processed.
If this value is 1
, the Autoprefixer "Support for IE Grid" option is enabled when running Autoprefixer. If the value is 0
, that option is set to false.
This controls which presets are used when running Babel. The value is a bitmask—each bit represents a boolean that controls a specific preset, as depicted in the table below. To turn a preset ON, set the corresponding bit to 1
. To turn a preset OFF, set the corresponding bit to 0
. (The default value is 1
, which enables the ENV
preset.)
Bit Position | Babel Preset |
---|---|
0 | ENV |
1 | React |
2 | Flow |
If this value is 1
, Babel will look for and load .babelrc
files while transpiling. If the value is 0
, those files will be ignored.
This String
is written after each change that Babel makes in transpiled code. The default value is an empty string: ""
This String
is written before each change that Babel makes in transpiled code. The default value is an empty string: ""
This controls where Babel gets its configuration. It is one of these values:
Value | Description |
---|---|
0 | Auto - Babel selects which plugins to use based on the BrowsersList string. (Babel-Preset-ENV) |
1 | Manual - The plugins and presets specified by the user in CodeKit's UI are used. |
2 | Config File - All configuration options from CodeKit are ignored and the user is responsible for configuring Babel with a Babel configuration file in the Project. |
This is a comma-separated list of additional plugins that should be passed to Babel. The user is responsible for installing these plugins in a node_modules
folder within the Project. The default value is an empty string: ""
This is a comma-separated list of additional presets that should be passed to Babel. The user is responsible for installing these presets in a node_modules
folder within the project. The default value is an empty string: ""
This is a comma-separated list of regex patterns that are passed to Babel as paths/items to skip when transpiling. The default value excludes any item with a path component matching node_modules
, core-js
, or bower_components
: "/\\/node_modules\\//, /\\/core-js\\//, /\\/bower_components\\//"
If this value is 1
, Babel will insert module IDs during transpiling. If the value is 0
, it will not.
This String
specifies the module ID to insert if babelInsertModuleIDs
is 1
. The default value is an empty string: ""
If this value is 1
, Babel will not insert auxiliary comments. If it is 0
, the comments specified in babelAuxiliaryCommentAfter
and babelAuxiliaryCommentBefore
will be inserted.
This is a list of all the standard Babel Plugins (those bundled with CodeKit) and whether they are enabled/disabled for this Project. Each entry in this Object looks like this:
"babelPlugins": {
"arrow-functions": {
"active": 0
},
...
}
Entries are keyed by the name of a specific plugin from the list below. If the plugin should be used when Babel runs, the active
property is set to 1
. If the plugin should NOT be used when Babel runs, set the active
property to 0
. Do not add any items other than those in the list below. To set custom plugins, use babelCustomPluginsList
.
NOTE: By default, Babel auto-selects which plugins to use based on the Browsers specified in the BrowsersList string. If you want to manually specify which plugins to run, you must set the babelConfigType
property to 1
.
List of Babel plugin names to use:
"arrow-functions"
"async-generator-functions"
"async-to-generator"
"block-scoped-functions"
"block-scoping"
"class-properties"
"classes"
"computed-properties"
"decorators"
"destructuring"
"do-expressions"
"dotall-regex"
"duplicate-keys"
"exponentiation-operator"
"export-default-from"
"external-helpers"
"flow-strip-types"
"for-of"
"function-bind"
"function-name"
"function-sent"
"inline-consecutive-adds"
"inline-environment-variables"
"instanceof"
"jscript"
"literals"
"logical-assignment-operators"
"member-expression-literals"
"merge-sibling-variables"
"minify-booleans"
"minify-builtins"
"minify-constant-folding"
"minify-dead-code-elimination"
"minify-flip-comparisons"
"minify-guarded-expressions"
"minify-infinity"
"minify-mangle-names"
"minify-numeric-literals"
"minify-simplify"
"minify-type-constructors"
"modules-amd"
"modules-commonjs"
"modules-systemjs"
"modules-umd"
"named-capturing-groups-regex"
"new-target"
"node-env-inline"
"nullish-coalescing-operator"
"numeric-separator"
"object-assign"
"object-rest-spread"
"object-set-prototype-of-to-assign"
"object-super"
"optional-catch-binding"
"optional-chaining"
"parameters"
"partial-application"
"pipeline-operator"
"private-methods"
"property-literals"
"property-mutators"
"proto-to-assign"
"react-constant-elements"
"react-display-name"
"react-inline-elements"
"react-jsx"
"react-jsx-compat"
"react-jsx-self"
"react-jsx-source"
"regenerator"
"regexp-constructors"
"remove-console"
"remove-debugger"
"remove-undefined"
"reserved-words"
"runtime"
"shorthand-properties"
"simplify-comparison-operators"
"spread"
"sticky-regex"
"strict-mode"
"template-literals"
"throw-expressions"
"typeof-symbol"
"undefined-to-void"
"unicode-property-regex"
"unicode-regex"
If this value is 1
, Babel will attempt to keep line numbers the same during transpiling. If the value is 0
, it will not.
This controls the useBuiltIns
Babel option. It is one of these values:
Value | UseBuiltIns Option |
---|---|
0 | False |
1 | Entry |
2 | Usage |
This String
provides the relative path from the Project Root Folder to the folder where Bower should install components. The default is "bower_components"
, which will create a subfolder with that name in the Project Root Folder.
If this value is 1
, Bower will automatically use the latest version of a component when a conflict arises. If the value is 0
, Bower will output an error and refuse to continue until the user resolves the conflict manually.
This controls to which dependency list in the bower.json
an installed component is added. It is one of these values:
Value | Dependency List |
---|---|
1 | Production |
2 | Development |
If this value is 1
, when a component is installed, the bower.json
file will specify that the exact version installed is required. If the value is 0
, the bower.json
file will use a semantic version string that allows any newer version of the component, up to but not including any version where the first non-zero version number has changed.
This is the number of seconds that CodeKit will wait between the end of processing a file and issuing a command to refresh browsers. It is useful for people working on remote servers, where there is a lag between the time a file finishes processing and the time it finishes uploading to the remote server's disk. The default value is 0
. The maximum value is 10
.
This String
is used by Autoprefixer and Babel (if Babel is set to auto-configure itself). The value MUST be a valid browserslist string or Autoprefixer and Babel will fail to run.
If this value is 1
, this Project uses a Build Folder. If the value is 0
, it does not. NOTE: When this setting is toggled in CodeKit, the app automatically adjusts every file's Output Path by either adding or removing the buildFolderName
to the beginning of the Output Path, as appropriate. If you change this setting manually, YOU are responsible for making sure the Output Path of each file (or the lanagugeDefaults
object used to automatically set Output Paths on each type of file) are set appropriately.
This is the name of the Build folder. It cannot be an empty string. The default value is "build"
.
If this value is 1
, CodeKit will delete everything in the Build folder before beginning a new Build. If the value is 0
, existing items will not be deleted when a new build starts.
.
.
.
.
This is the top-level property named buildSteps
, which is an Array
of {"string": value}
. There are currently three types of Build Steps:
- "run a script"
- "process specific files"
- "process all remaining files"
The buildSteps
Array may contain any number of the first two types and exactly one of the third type. The order matters; it is the order in which the user expects the steps to execute. Each type of Build Step has a slightly different structure: