Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(cmf): simplify imports #1359

Merged
merged 19 commits into from
May 28, 2018
Merged

Conversation

jmfrancois
Copy link
Contributor

@jmfrancois jmfrancois commented May 21, 2018

What is the problem this PR is trying to solve?

having api create more troubles than it solves anything.
The first idea of { api } was to expose only what the developer needs.
We are in progress to make cmf a framework and so we need to make import simple and easy to understand.

What is the chosen solution to this problem?

So no more { api } just index, so all the things are accessible from index and more and more we will remove all deprecated stuff in the following PRs.
Let's introduce the default export 'cmf':

import cmf from '@talend/react-cmf';

This will replace { api } and provide more and less stuff;
the next step is #1293 (bootstrap)

Please check if the PR fulfills these requirements

  • The PR commit message follows our guidelines
  • Tests for the changes have been added (for bug fixes / features) And non reg done before need review
  • Docs have been added / updated (for bug fixes / features)
  • Related design / discussions / pages (not in jira), if any, are all linked or available in the PR

[ ] This PR introduces a breaking change

'getCollection',
'dispatch',
'dispatchActionCreator',
];
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

moved in constant

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@jmfrancois jmfrancois changed the title chore(cmf): move from api to index chore(cmf): simplify imports May 21, 2018
@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

1 similar comment
@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@@ -80,11 +81,11 @@ api.action.getOnProps(props);

It returns the array of props keys beginning with `on`. This is used to get the list of action props (onClick, onKeyDown, ...).

## mapDispatchToProps
## mapDispatchToProps (DEPRECATED)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if deprecated please remove doc to avoid people to keep using it

@@ -67,11 +68,11 @@ It creates the action to dispatch from
* the provided user `event`
* the provided user `data`

## getOnProps
## getOnProps (DEPRECATED)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if deprecated please remove doc to avoid people to keep using it

@@ -47,11 +48,11 @@ api.action.getActionInfo(context, id);

It returns the static `action` definition from the settings.

## getActionObject
## getActionObject (DEPRECATED)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if deprecated please remove doc to avoid people to keep using it

@@ -33,11 +34,11 @@ api.actionCreator.get(context, id);

It returns the registered `action creator` from the provided registry.

## getActionInfo
## getActionInfo (DEPRECATED)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if deprecated please remove doc to avoid people to keep using it

@@ -6,11 +6,12 @@ date: 2017-02-28 22:10:38
order: 3
---

## getActionsById
## getActionsById (DEPRECATED)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if deprecated please remove doc to avoid people to keep using it

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@build-travis-ci
Copy link
Collaborator

:octocat: Demo is available here

@jmfrancois jmfrancois merged commit 02a75f5 into master May 28, 2018
@jmfrancois jmfrancois deleted the jmfrancois/chore/cmf-api-to-index branch May 28, 2018 07:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants