86 Commits
Author SHA1 Message Date
Andrey Sitnik a3b6886f68 Fix Node[my] hack 2021-06-14 09:23:43 -04:00
Andrey SitnikandGitHub 2c6777648a Merge pull request #1582 from hudochenkov/add-document-node-1498
Add Document node and related API (#1498)
2021-05-18 20:46:25 -04:00
Aleks Hudochenkov bd17ae8ec9 Remove Node#document() 2021-05-18 02:01:20 +02:00
Jonathan NealandAndrey Sitnik f070b51ff1 feat: Node#assign
The `assign` function lets authors assign multiple properties to a node from a single object.

This can improve code clarity when updating multiple properties while offering a helpful typing experience.
2021-05-17 08:50:29 -04:00
Aleks Hudochenkov 430ee0d902 Add Document node and related API (#1498) 2021-05-16 20:15:56 +02:00
Andrey Sitnik 843ab11b6e Add Prettier 2021-03-11 19:11:37 -05:00
Andrey Sitnik 4d9a51a72b Fix Node#toJSON and proxyCache 2021-02-10 13:33:59 -05:00
Niklas Mischkulnig b3405e610c Fix JSON.stringify of an array of nodes 2021-01-07 12:04:45 +01:00
Niklas Mischkulnig e22b4711d4 Fix test/don't remove source.end 2020-12-09 12:31:53 +01:00
Niklas Mischkulnig 1142d0f544 Rename to input/inputId 2020-12-09 12:31:53 +01:00
Niklas Mischkulnig bf6ce4b9fb Deduplicate Input objects in JSON 2020-12-09 12:31:53 +01:00
Niklas Mischkulnig fd91269044 All nodes have a source property, not just Root 2020-12-09 12:31:53 +01:00
Niklas Mischkulnig ec69e352d9 fromJSON and toJSON 2020-12-05 00:15:24 +01:00
Remco Haszing b94a22e19f Fix usage of default exports with TypeScript
This is done by assigning the property `default` for all properties that are
exported using `export default` according to their type definitions.

Closes #1424
2020-11-10 14:24:37 +01:00
Andrey Sitnik c20d10df29 Fix visiting parent on nested children changes 2020-09-23 18:47:27 -04:00
Andrey Sitnik 8f8bfe31d7 Fix child adding methods in Container 2020-09-20 12:47:05 -04:00
Andrey Sitnik 0048657b13 Add "use strict" because it may effect on tokenizer performance 2020-09-08 01:46:46 -04:00
Andrey Sitnik 887783b405 Change plugin running code and mark moved nodes as dirty 2020-09-05 00:31:30 -04:00
Andrey Sitnik 1ae90b7f70 Speed up PostCSS 2020-09-02 22:17:01 -04:00
Andrey Sitnik 15d0f4b7e4 Speed up async visitor API 2020-09-01 00:12:25 -04:00
Andrey Sitnik 6df84fce5e Fix two args walk methods in proxies 2020-08-24 21:24:28 -05:00
Andrey Sitnik 8b5c41e777 Prevent loop with visitor API 2020-08-22 14:56:49 -05:00
Andrey Sitnik 6fbb0d5434 Change plugin API 2020-08-06 16:00:46 -07:00
Andrey Sitnik c3b3015661 Improve test coverage 2020-08-04 17:37:21 -07:00
Andrey Sitnik 8aae507a45 Clean up types and replace JSDoc to TypeDoc 2020-07-08 17:55:13 -07:00
Andrey Sitnik fa6b5f9981 Add PrettierX 2020-07-06 17:24:57 -07:00
Joseph KapturandAndrey Sitnik 688279df21 Allow replaceWith to be called with input that includes itself. (#1368)
* Allow replaceWith to be called with a list of nodes that includes the node itself.

* Fix semicolons

* Fix semicolons
2020-06-21 19:13:54 -04:00
Andrey Sitnik 5d99a77f30 Move nodes in constructor fix from 7.0.19 2020-06-21 19:13:53 -04:00
Andrey Sitnik 7a0bf06706 Clean up visitor API 2020-06-21 19:13:53 -04:00
Andrey Sitnik 288d2ffdb6 Clean up code 2020-06-21 19:13:53 -04:00
Andrey Sitnik 6407a95d28 Update dependencies 2020-06-21 19:13:53 -04:00
Andrey Sitnik 04b816cbde Remove Babel 2020-06-21 19:13:52 -04:00
Andrey Sitnik f43a45a907 Use .es6 ext for ES6 sources 2015-08-17 16:20:40 +03:00
Andrey Sitnik 8a278b8757 Change custom syntax options 2015-08-17 16:20:39 +03:00
Andrey Sitnik ab400d3b1d Add optional stringifier to Node#toString() 2015-08-17 16:20:38 +03:00
Andrey Sitnik 2c116fd933 Change custom syntaxes API 2015-08-17 16:20:38 +03:00
Andrey Sitnik 615715be68 Add word option to Node#error 2015-08-17 16:20:38 +03:00
Andrey Sitnik 7cfa8dc4ea Clean up Node#positionInside code 2015-08-17 16:20:38 +03:00
Andrey Sitnik fe5acddc4f Add options to change PostCSS syntax 2015-08-17 16:20:37 +03:00
Andrey Sitnik 42dd6ebfcb Move Node#style to Stringifier 2015-08-17 16:20:37 +03:00
Andrey Sitnik 137024f2b8 Fix depreacted getters for raw properties 2015-08-17 16:20:37 +03:00
Andrey Sitnik b76b5a34fc Move code style properties to Node#raw 2015-08-17 16:20:37 +03:00
Andrey Sitnik 7d6f4de392 Make stringifier as a class 2015-08-17 16:20:37 +03:00
Andrey Sitnik c128e5b954 Clean up code styles 2015-08-17 16:20:37 +03:00
Andrey Sitnik a6efbaf345 Move stringifing to separated file 2015-08-17 16:20:37 +03:00
Jonathan NealandAndrey Sitnik 2a36aae2b6 Use ES6 conventions
- `…thing`
- `for (thing of things)`
2015-08-17 16:20:37 +03:00
David ClarkandAndrey Sitnik cddbf99b11 PoC for positionAt 2015-08-17 16:20:37 +03:00
Jonathan NealandAndrey Sitnik 7e3da3c1b3 Support multiple nodes on DOM4 methods
Support multiple nodes on append, prepend, and replaceWith
2015-08-17 16:20:37 +03:00
Andrey Sitnik 94732f3bf1 Speed up node.clone() 2015-05-05 13:29:51 +03:00
Andrey Sitnik 709200a2b4 Lint code with ESLint 2015-03-14 22:02:49 +03:00