mirror of
https://github.com/danbulant/oxc
synced 2026-05-19 04:08:41 +00:00
refactor(transformer/object-rest-spread): move plugin-relates files to object_rest_spread mod (#5320)
Both `object_spread` and `object_rest` belong to `object_rest_object`, so moving them to the plugin mod makes the file structure clearer
This commit is contained in:
parent
164511549f
commit
d2666fe039
4 changed files with 8 additions and 6 deletions
|
|
@ -1,6 +1,4 @@
|
|||
mod object_rest;
|
||||
mod object_rest_spread;
|
||||
mod object_spread;
|
||||
mod options;
|
||||
|
||||
pub use object_rest_spread::{ObjectRestSpread, ObjectRestSpreadOptions};
|
||||
|
|
|
|||
|
|
@ -28,12 +28,14 @@
|
|||
|
||||
use crate::context::Ctx;
|
||||
|
||||
use object_rest::ObjectRest;
|
||||
use object_spread::ObjectSpread;
|
||||
use oxc_ast::ast::*;
|
||||
use oxc_traverse::{Traverse, TraverseCtx};
|
||||
use serde::Deserialize;
|
||||
use std::rc::Rc;
|
||||
|
||||
use super::{object_rest::ObjectRest, object_spread::ObjectSpread};
|
||||
mod object_rest;
|
||||
mod object_spread;
|
||||
|
||||
#[derive(Debug, Default, Clone, Copy, Deserialize)]
|
||||
#[serde(default, rename_all = "camelCase")]
|
||||
|
|
@ -24,9 +24,10 @@
|
|||
//! * Babel plugin implementation: <https://github.com/babel/babel/tree/main/packages/babel-plugin-transform-object-rest-spread>
|
||||
//! * Object rest/spread TC39 proposal: <https://github.com/tc39/proposal-object-rest-spread>
|
||||
|
||||
use super::object_rest_spread::ObjectRestSpreadOptions;
|
||||
use crate::context::Ctx;
|
||||
|
||||
use super::ObjectRestSpreadOptions;
|
||||
|
||||
pub struct ObjectRest<'a> {
|
||||
_ctx: Ctx<'a>,
|
||||
_options: ObjectRestSpreadOptions,
|
||||
|
|
@ -26,7 +26,6 @@
|
|||
//! * Babel plugin implementation: <https://github.com/babel/babel/tree/main/packages/babel-plugin-transform-object-rest-spread>
|
||||
//! * Object rest/spread TC39 proposal: <https://github.com/tc39/proposal-object-rest-spread>
|
||||
|
||||
use super::object_rest_spread::ObjectRestSpreadOptions;
|
||||
use crate::context::Ctx;
|
||||
|
||||
use oxc_ast::ast::*;
|
||||
|
|
@ -34,6 +33,8 @@ use oxc_semantic::{ReferenceFlags, SymbolId};
|
|||
use oxc_span::SPAN;
|
||||
use oxc_traverse::{Traverse, TraverseCtx};
|
||||
|
||||
use super::ObjectRestSpreadOptions;
|
||||
|
||||
pub struct ObjectSpread<'a> {
|
||||
_ctx: Ctx<'a>,
|
||||
options: ObjectRestSpreadOptions,
|
||||
Loading…
Reference in a new issue